summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_posewidget
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-12-04 18:46:27 +0100
committerStanislaw Halik <sthalik@misaki.pl>2013-12-04 18:46:27 +0100
commit79119a08157aa954b3b2ecd18c8384b80a03970f (patch)
treedb5332566e6a76f74699bb6eaf146005020e8026 /ftnoir_posewidget
parent5d51487b70a07f1853f1cbcf84ac5eb635e38bbe (diff)
draw images directly, without pixmaps
Diffstat (limited to 'ftnoir_posewidget')
-rw-r--r--ftnoir_posewidget/glwidget.cpp4
-rw-r--r--ftnoir_posewidget/glwidget.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/ftnoir_posewidget/glwidget.cpp b/ftnoir_posewidget/glwidget.cpp
index 71af8a08..93c98c9c 100644
--- a/ftnoir_posewidget/glwidget.cpp
+++ b/ftnoir_posewidget/glwidget.cpp
@@ -26,7 +26,7 @@ void GLWidget::paintEvent ( QPaintEvent * event ) {
QWidget::paintEvent(event);
QPainter p(this);
project_quad_texture();
- p.drawPixmap(event->rect(), pixmap, event->rect());
+ p.drawImage(event->rect(), texture);
}
void GLWidget::rotateBy(double xAngle, double yAngle, double zAngle)
@@ -226,5 +226,5 @@ void GLWidget::project_quad_texture() {
}
}
}
- pixmap = QPixmap::fromImage(texture);
+ this->texture = texture;
}
diff --git a/ftnoir_posewidget/glwidget.h b/ftnoir_posewidget/glwidget.h
index 0bb693c8..c4b2e09d 100644
--- a/ftnoir_posewidget/glwidget.h
+++ b/ftnoir_posewidget/glwidget.h
@@ -91,7 +91,7 @@ private:
double matrix[9];
QImage front;
QImage back;
- QPixmap pixmap;
+ QImage texture;
};
#endif