Revision: 78261
http://sourceforge.net/p/brlcad/code/78261
Author: starseeker
Date: 2021-02-18 15:33:14 +0000 (Thu, 18 Feb 2021)
Log Message:
-----------
There we go - get resizing working. This is a full render for every paint
event, which is too slow, but we can now resize with expected result.
Modified Paths:
--------------
brlcad/trunk/src/isst/isstgl.cpp
Modified: brlcad/trunk/src/isst/isstgl.cpp
===================================================================
--- brlcad/trunk/src/isst/isstgl.cpp 2021-02-18 14:56:08 UTC (rev 78260)
+++ brlcad/trunk/src/isst/isstgl.cpp 2021-02-18 15:33:14 UTC (rev 78261)
@@ -45,8 +45,18 @@
{
QPainter painter(this);
+ camera.w = width();
+ camera.h = height();
+ tile.size_x = camera.w;
+ tile.size_y = camera.h;
+
TIENET_BUFFER_SIZE(buffer_image, (uint32_t)(3 * camera.w * camera.h));
+ // IMPORTANT - this reset is necessary or the resultant image will
+ // not display correctly in the buffer.
+ buffer_image.ind = 0;
+
+ render_camera_prep(&camera);
render_camera_render(&camera, tie, &tile, &buffer_image);
QImage *image = new QImage(buffer_image.data, camera.w, camera.h,
QImage::Format_RGB888);
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits