mirror of
https://github.com/creyD/intelliphoto.git
synced 2026-04-12 19:40:28 +02:00
Uncrustified Files
This commit is contained in:
@@ -5,9 +5,9 @@
|
||||
#include <QDebug>
|
||||
|
||||
IntelliShapedImage::IntelliShapedImage(int width, int height, bool fastRendererOn)
|
||||
: IntelliRasterImage(width, height, fastRendererOn){
|
||||
TypeOfImage = IntelliImage::ImageType::SHAPEDIMAGE;
|
||||
this->fastRenderering = fastRendererOn;
|
||||
: IntelliRasterImage(width, height, fastRendererOn){
|
||||
TypeOfImage = IntelliImage::ImageType::SHAPEDIMAGE;
|
||||
this->fastRenderering = fastRendererOn;
|
||||
}
|
||||
|
||||
IntelliShapedImage::~IntelliShapedImage(){
|
||||
@@ -27,9 +27,9 @@ IntelliImage* IntelliShapedImage::getDeepCopy(){
|
||||
}
|
||||
|
||||
void IntelliShapedImage::calculateVisiblity(){
|
||||
if(fastRenderering){
|
||||
this->imageData = imageData.convertToFormat(QImage::Format_ARGB32);
|
||||
}
|
||||
if(fastRenderering) {
|
||||
this->imageData = imageData.convertToFormat(QImage::Format_ARGB32);
|
||||
}
|
||||
|
||||
if(polygonData.size()<=2) {
|
||||
QColor clr;
|
||||
@@ -40,9 +40,9 @@ void IntelliShapedImage::calculateVisiblity(){
|
||||
imageData.setPixelColor(x,y,clr);
|
||||
}
|
||||
}
|
||||
if(fastRenderering){
|
||||
this->imageData = this->imageData.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
if(fastRenderering) {
|
||||
this->imageData = this->imageData.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
return;
|
||||
}
|
||||
QColor clr;
|
||||
@@ -59,16 +59,16 @@ void IntelliShapedImage::calculateVisiblity(){
|
||||
imageData.setPixelColor(x,y,clr);
|
||||
}
|
||||
}
|
||||
if(fastRenderering){
|
||||
this->imageData = this->imageData.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
if(fastRenderering) {
|
||||
this->imageData = this->imageData.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
}
|
||||
|
||||
QImage IntelliShapedImage::getDisplayable(const QSize& displaySize, int alpha){
|
||||
QImage copy = imageData;
|
||||
if(fastRenderering){
|
||||
copy = copy.convertToFormat(QImage::Format_ARGB32);
|
||||
}
|
||||
if(fastRenderering) {
|
||||
copy = copy.convertToFormat(QImage::Format_ARGB32);
|
||||
}
|
||||
for(int y = 0; y<copy.height(); y++) {
|
||||
for(int x = 0; x<copy.width(); x++) {
|
||||
QColor clr = copy.pixelColor(x,y);
|
||||
@@ -76,9 +76,9 @@ QImage IntelliShapedImage::getDisplayable(const QSize& displaySize, int alpha){
|
||||
copy.setPixelColor(x,y, clr);
|
||||
}
|
||||
}
|
||||
if(fastRenderering){
|
||||
copy = copy.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
if(fastRenderering) {
|
||||
copy = copy.convertToFormat(QImage::Format_Indexed8);
|
||||
}
|
||||
return copy.scaled(displaySize,Qt::IgnoreAspectRatio);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user