POV-Ray

The Persistence of Vision Raytracer (POV-Ray).

This is the legacy Bug Tracking System for the POV-Ray project. Bugs listed here are being migrated to our github issue tracker. Please refer to that for new reports or updates to existing ones on this system.

Attached to Project: POV-Ray
Opened by Grimbert Jérôme - 2013-12-15
Last edited by William F Pokorny - 2016-10-11

FS#317 - problem with +D option at specific output file dimensions

Reported in p.beta-test by James Dietrich (2013-12-12)

when the display window must be scaled (because one or both dimensions are larger than the actual screen), the ratio of scale might be too large in some occasion, performing a memory corruption in two places and usually crashing povray.

How to reproduce, with a 1920×1080 display (or 1920×1200):

povray +W2596 +H1003 +Ispiral.pov +Ospiral.png +D

Closed by  William F Pokorny
Tuesday, 11 October 2016, 16:33 GMT
Reason for closing:  Fixed
Additional comments about closing:  

Verified fixed in 3.7.1 master branch. 3.7.0-stable fails. git commit 7ae56bc was Jerome Grimbert, 2 years, 10 months ago, message: Fixing fs#317

Grimbert Jérôme commented on Sunday, 15 December 2013, 08:49 GMT

Proposed solution:

--- a/unix/disp_sdl.cpp Sun Dec 15 09:22:35 2013 +0100
+++ b/unix/disp_sdl.cpp Sun Dec 15 09:47:46 2013 +0100
@@ -242,7 +242,12 @@
                        else
                        {
                                m_display_scaled = true;
-                               m_display_scale = float(width) / GetWidth();
+        /* [JG] the scaling factor between the requested resolution and the actual window is the same in both direction
+         * yet, the factor (as a float) need the smallest value to avoid an access out of the two buffers for the pixels. 
+         * The difference is nearly invisible until the values of GetWidth and GetHeight are subtil (such as +W2596 +H1003 on a display of 1920 x 1080)
+         * where in such situation, the computed ratio is not exactly the same as the other.
+         */
+                               m_display_scale = min( float(width) / GetWidth(), float(height) / GetHeight() );
                        }
 
                        SetCaption(false);

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing