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.

IDCategoryTask TypeReported InPrioritySeveritySummaryStatus  descProgressDue In Version
70PhotonsUnimp. Feature/TODO3.70 beta 34LowHighload/save photons should be controlled via command lineTracked on GitHub
0%
Task Description

Just like radiosity load/save, the photon mapping load/save mechanism should be moved to the frontend and controlled via command-line switch, instead of being SDL-driven in the backend.

306Subsurface ScatteringDefinite Bug3.70 RC7Very LowHighfinish subsurface block before global_settings subsurfa...Tracked on GitHub
0%
3.71 release Task Description

The following scene causes a crash:

sphere {
  <0,0,0>, 1
  finish { subsurface { translucency 1.0 } }
}

global_settings {
  subsurface { }
}
7RadiosityUnimp. Feature/TODO3.70 beta 32LowMediumRe-implement Radiosity render abort/continue supportTracked on GitHub
0%
Task Description

For proper render abort/continue support, radiosity cache data must be written to (or read from) disk even if the user does not explicitly opt to have a sample data file written/read. This feature has temporarily been dropped from 3.7 beta and is still pending re-implementation.

To meet high-reproducibility requirements in conjunction with SMP operation, it may be necessary to extend the 3.6 radiosity cache file format.

42OtherDefinite Bug3.70 beta 32Very LowMediumcommand line parameters are not parsed properly on UnixTracked on GitHub
0%
Task Description

POV-Ray does not follow common practice on command-line handling; for instance:

povray +i"My File"

entered on a Unix shell would be passed to POV-Ray as

povray
+iMy File

(each line representing a distinct parameter here), which POV-Ray would further dissect, interpreting it as

povray
+iMy
File

To achieve the desired effect, one would actually have to quote the string twice:

povray +i"'My File'"

which the shell would translate to

povray
+i'My File'

which POV-Ray would interpret as

povray
+iMy File

In both cases, this is obviously not what a Unix user would expect.

The further dissecting of individual command-line parameters may have had its valid roots in the peculiarities of DOS’ command-line handling, but to my knowledge all major contemporary operating systems follow a concept akin to Unix, passing a list of parameters instead of a monolithic command line, and burdening the respective command shells with the task of dissecting command lines into parameters.

Therefore I suggest to disable this anachronistic feature in favor of contemporary standards; a compiler flag might be used to allow for easy re-enabling of the feature, for compiling POV-Ray on exotic targets.

- edit -

It has been pointed out that the described behaviour differs from 3.6, so I’m promoting this to a bug and changing the title.

50Runtime errorPossible Bug3.70 beta 32Very LowMediumFrequent segfaults with photon scenesTracked on GitHub
0%
Task Description

I observe frequent segfaults with POV-Ray 3.7 betas when rendering scenes using photons:

  • Debian Linux 4.0r5 “etch” for AMD64
  • AMD Phenom X4 9650 2.3GHz, 6 GB RAM
  • POV-Ray compiled with Intel icpc 11.0

Segfaults are sporadic but frequent (occurring in roughly 50% of all photon renders).

60Geometric PrimitivesDefinite Bug3.70 beta 34Very LowMediumArtifacts using prism in CSGTracked on GitHub
0%
Future release Task Description

Using prisms in intersecion or difference CSG objects may cause artifacts in POV-Ray 3.6.2 as well as 3.7.0.beta.34, as demonstrated by the following code:


camera {
  right    -x
  up        y*image_height/image_width
  location  <-24,19,12>
  look_at   <0,0,0>
}

light_source { <100,200,100> color rgb 1 }

plane { y, -2 pigment { color rgb 1 } }


#declare KeyValue = 1.366; // pick any you like

difference {
  prism {
    linear_sweep -0.5,0.5, 4
    
    <-3,20-17>,
    <-3,KeyValue>,
    <-6,-3>,
    <-0,-5>
  }
  intersection {
    cylinder { <-7,-0.51,1>, <-7, 0.51,1>, 4.0 }
    plane { z, KeyValue }
  }
  pigment { color rgb 0.5 } 
}

Apparently the surface of the other object becomes visible when it exactly coincides with a vertex of the prism; probably there is a failure of the inside() test for such values.

98Refactoring/CleanupUnimp. Feature/TODO3.70 beta 36DeferMediumRefactor Windows UI code for Unicode supportTracked on GitHub
50%
Future release Task Description

Windows UI code should be refactored to use _TCHAR throughout instead of char, as well as the corresponding string function macros, to head for Unicode support.

251Parser/SDLPossible Bug3.70 RC6Very LowMediumScene / include files of >2GB size may cause problemsTracked on GitHub
0%
3.71 release Task Description

Code inspection shows that we’re still using fseek() and ftell() in various places (including text file input), which can’t handle file positions of 2GB and beyond (except on 64-bit linux machines); those calls need to be examined and (where appropriate) replaced with the fseek64() macro we’re already defining (but currently not using), and a to-be-defined ftell64() macro.

One potential (untested) error scenario would be a scene file calling a macro that is defined at the end of a > 2GB long include file.

4Subsurface ScatteringUnimp. Feature/TODO3.70 beta 32Very LowLowIntegrate Subsurface Scattering with standard lighting ...Tracked on GitHub
90%
Future release Task Description

Subsurface Scattering still uses its own rudimentary code to compute illumination from classic light sources; this must be changed to use the standard light source & shadow handling code, to add support for non-trivial light sources (e.g. spotlights, cylindrical lights, area lights), partially-transparent shadowing objects etc.

6Subsurface ScatteringUnimp. Feature/TODO3.70 beta 32DeferLowIntegrate Subsurface Scattering with PhotonsTracked on GitHub
0%
Future release Task Description

Subsurface scattering must be made photon-aware.

8RadiosityUnimp. Feature/TODO3.70 beta 32DeferLowImprove Radiosity "Cross-Talk" Rejection in CornersTracked on GitHub
0%
Future release Task Description

Near concave edges, radiosity samples may be re-used at a longer distance away from the edge than towards the edge; there is code in place to ensure this, but it only works properly where two surfaces meet roughly rectangularly, while failing near the junction of three surfaces or non-rectangular edges, potentially causing “cross-talk”.

It should be investigated how the algorithm can be improved or replaced to better cope with non-trivial geometry.

41OtherFeature Request3.70 beta 32Very LowLowimprove command-line parsing error messagesTracked on GitHub
0%
Task Description

POV-Ray 3.6, upon encountering problems when parsing command line and/or .ini file options, would quote the offending option in the error message.

POV-Ray 3.7 currently just reports that there is some problem with the command line, without providing any details. I suggest changing this, as the information may be helpful at times.

44RadiosityFeature RequestAllVery LowLowImprove Normals Handling in RadiosityTracked on GitHub
0%
Future release Task Description

Currently, radiosity does not make use of the fact that pertubed normals would theoretically just require a different weighting of already-sampled rays, leading to the following issues:

  • Honoring normal pertubations in radiosity leads to an increased number of samples, slowing down sample cache lookup.
  • The increased number of samples is generated from a proportionally higher number of sample rays, slowing down pretrace even further.
  • Low-amplitude pertubations tend to be smoothed out; “reviving” these is only possible by increasing the general sample density.
  • Handling of multi-layered textures with different normal pertubations is currently poorly implemented.

As a solution, I propose to store for each radiosity sample not only the resulting illumination for a perfectly unpertubed normal, but from the same set of sample rays also compute the illumination for an additional set of about a dozen standardized pertubed-normal directions, and interpolate among these when computing the radiosity-based illumination for a particular point that has a pertubed normal.

For backwards compatibility, this method of dealing with pertubed normals in radiosity might be activated by a different value for the “normal” statement in the radiosity block, say, “normal 2”.

58Parser/SDLUnimp. Feature/TODO3.70 beta 32DeferLowallow SDL code to detect optional featuresTracked on GitHub
0%
Task Description

Some features are optional in custom builds of POV-Ray (I’m thinking about OpenEXR in particular); it would be nice to have a syntax for an SDL script to check for support of such features, so it may take some fallback action if the feature is not supported.

65Parser/SDLFeature Request3.70 beta 34Very LowLowAdd support for vectors with functionsTracked on GitHub
0%
Future release Task Description

Being able to have functions operate on vectors would be pretty nice to have.

96Texture/Material/FinishFeature RequestNot applicableVery LowLowUser-defined warpsTracked on GitHub
0%
Future release Task Description

User-defined warps would be nice to have, something along the lines of:

warp {
  function { MyFnX(x,y,z) } // function to compute pattern-space x-coordinate from object-space <x,y,z> coordinate
  function { MyFnY(x,y,z) } // ditto for pattern-space y coordinate
  function { MyFnZ(x,y,z) } // ditto for pattern-space z coordinate
}

// a displacement warp:
warp {
  function { x + MyFnX(x,y,z) }
  function { y + MyFnY(x,y,z) }
  function { z + MyFnZ(x,y,z) }
}
106DistributionUnimp. Feature/TODO3.70 beta 37Very LowLowUpdate sample scenes and include files for POV-Ray 3.7 ...Tracked on GitHub
0%
Task Description

Most sample scenes and include files were designed at times when POV-Ray did not to any proper gamma handling, or still used the inferior 3.6 “assumed_gamma” mechanism.

All the scenes and include files should be reviewed, and updated to fit the new 3.7 gamma model.

The primary task will probably be gamma-adjusting literal color values and ambient parameters; I suggest using macros (which ideally should be defined in an include file) to be set according to the #version statement, so the scene/include file could be kept compatible with older versions.

172Image formatUnimp. Feature/TODO3.70 beta 39Very LowLowRe-implement progressive image outputTracked on GitHub
0%
Future release Task Description

With previous versions of POV-Ray, it was possible to turn off display output, but still assess the output during render by viewing the output file as it was progressively generated. This allowed e.g. to run a long render on a remote machine as a background process, and check the output from time to time via FTP or similar.

177Light sourceFeature Request3.70 beta 39Very LowLowAdd support for conserve_energy to shadow computationsTracked on GitHub
0%
Task Description

The following scene gives a comparison of current conserve_energy handling in standard shadow computations vs. photons.

Note how the rather highly reflective slabs fail to cast shadows, except where the photons target sphere enforces computation of shadow brightness to be done by the photons algorithm.

For more realistic shadowing without the need to enable photons, I suggest do add proper conserve_energy handling to the shadow computation code (which shouldn’t be too much effort).

global_settings {
  max_trace_level 10
  photons { spacing 0.003 media 10 }
}

camera {
  right x*image_width/image_height
  location  <-2,2.6,-10>
  look_at   <0,0.75,0>
}

light_source {
  <500,300,150>
  color rgb 1.3
  photons {
    refraction on
    reflection on
  }
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

plane {
  y, 0
  texture { pigment { color rgb 0.7 } }
}

#declare M_Glass=
material {
  texture {
    pigment {rgbt 1}
    finish {
      ambient 0.0
      diffuse 0
      specular 0.2 // just to give a hint where the sphere is
    }
  }
  interior { ior 1.0 }
}

#declare M_PseudoGlass=
material {
  texture {
    pigment {rgbt 1}
    finish {
      ambient 0.0
      diffuse 0.5
      specular 0.6
      roughness 0.005
      reflection { 0.3, 1.0 fresnel on }
      conserve_energy
    }
  }
  interior { ior 1.5 }
}


sphere {
  <1.1,1,-1.3>, 1
  material { M_Glass }
  photons {
    target 1.0
    refraction on
    reflection on
  }
}

// behind target object
box {
  <-0.2,0,-2.3>, <0.0,4,0.3>
  material { M_PseudoGlass }
  rotate z*1 // just to better see the reflection of the horizon
}

// before target object
box {
  <2.4,0,-2.3>, <2.6,4,-0.3>
  material { M_PseudoGlass }
  photons { pass_through }
  rotate z*1 // just to better see the reflection of the horizon
}
178Texture/Material/FinishFeature Request3.70 beta 39Very LowLowModify metallic reflection code to better work with con...Tracked on GitHub
0%
Task Description

The combination of metallic reflection with conserve_energy causes the reflection to lose colour, as demonstrated by the following scene:

global_settings {
  max_trace_level 10
}

camera {
  right x*image_width/image_height
  location  <-2,2.6,-10>
  look_at   <0,0.75,0>
}

light_source {
  <500,300,150>
  color rgb 1.3
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

plane {
  y, 0
  texture { pigment { color rgb 0.7 } }
}

#declare M=
material {
  texture {
    pigment {rgbt <1.0,0.7,0.2,0.99>}
    finish {
      ambient 0.0
      diffuse 0.5
      specular 0.6
      roughness 0.005
      reflection { 0.8, 1.0 metallic }
      conserve_energy
    }
  }
  interior { ior 1.5 }
}

box {
  <-0.2,0,-2.3>, <0.0,4,0.3>
  material { M }
  rotate z*5
  rotate x*2
}
183Texture/Material/FinishPossible Bug3.70 beta 40Very LowLowcutaway_textures broken with child unionsTracked on GitHub
50%
Future release Task Description

When using cutaway_textures in a CSG object that has union children, results are not as expected; instead, surfaces in the union children that have no explicit texture will be rendered with the default texture instead. This is not the case for e.g. difference children.

Example:

#default { texture { pigment { rgb 1 } } }

camera {
  right x*image_width/image_height
  location  <0,1.5,-4>
  look_at   <0,1,0>
}

light_source { <500,500,-500> color rgb 1 }

#declare U = union {
  sphere { <0,-0.1,-1>, 0.3 }
  sphere { <0, 0.1,-1>, 0.3 pigment { color red 1 } }
}

intersection {
  sphere { <0,0,0>, 1 pigment { color green 1 } }
  object { U }
  cutaway_textures
  rotate y*90
}

When declaring U as an intersection instead, the results are as expected, with the surface of the first sphere in U being rendered with the texture defined in the outer intersection.

205DocumentationUnimp. Feature/TODO3.70 RC3Very LowLowSyntax documentation uses inconsistent notationTracked on GitHub
0%
Task Description

The syntax notation used in the main documentation is different than that used in the quick-reference section. This should be changed for consistency, using the superior quick-reference notation throughout.

248Parser/SDLFeature RequestNot applicableVery LowLowImplement mechanism to compute direction of a splineTracked on GitHub
0%
Future release Task Description

The SDL currently provides no way to compute the exact direction of a spline at a given location, even though mathematically this is a piece of cake: The first-order derivative of any spline section gives you the “speed” as a vector function, and is trivial to compute for polynomial splines (which are behind all spline types that POV-Ray supports); the normalized “speed” vector, in turn, gives the “pure” direction.

For exact direction/speed computations, I propose to extend the SDL invocation syntax as follows to allow for evaluating a spline’s derivative:

    SPLINE_INVOCATION:
        SPLINE_IDENTIFIER ( FLOAT [, SPLINE_TYPE] [, FLOAT] )

or

    SPLINE_INVOCATION:
        SPLINE_IDENTIFIER ( FLOAT [, FLOAT] [, SPLINE_TYPE] )

where the second FLOAT will specify the order of derivative to evaluate (defaulting to 0). In order to compute the position, direction, and acceleration of an object traveling along a certain spline, one could then for instance use:

    #declare S        = spline { ... }
    #declare Pos      = S(Time);
    #declare VSpeed   = S(Time,1);
    #declare VAccel   = S(Time,2);
    #declare Dir      = vnormalize(VSpeed);
    #declare Speed    = vlength(VSpeed);
    #declare AccelDir = vnormalize(VAccel);
    #declare GForce   = vlength(VAccel) / 9.81;

Alternatively, a mechanism may be devised to create a spline representing another spline’s derivative; however, it would be debatable whether the syntax should be parameter-like (being an added information that could be overridden again when creating other splines from such a derived spline), or operation-like (converting the spline), and in the latter case how it should affect spline type (and consequently control points); so the spline invocation parameter approach might be more straightforward, with less potential surprises for the user.

264PhotonsUnimp. Feature/TODO3.70 RC6DeferLowImprove precision of photon direction informationTracked on GitHub
0%
Task Description

In the photons map, the direction of each photon is stored as separate latitude & longitude angles (encoded in one byte each), causing the longitudinal direction component’s precision to be unnecessarily high for directions close to the “poles” (Y axis); in addition, encoded value -128 is never used. For better overall precision as well as precision homogenity, the following scheme could be used instead:

  • Encode the latitude (-pi/2 to +pi/2) into LatCount=226 distinct values (= 256*sqrt(pi)/2) rounded to the next even number) from 0 to LatCount-1 using
latCode = (int)((LatCount-1) * (lat/M_PI + 0.5) + 0.5)
  • For each latitude code, define a specific number of encodable longitude values, LngCount[latCode] = approx. cos(lat)*pi*65536/(2*LatCount); this can be a pre-computed table, and may need slight tweaking for optimum use of the code space. Encode the longitude (-pi to +pi) into a value from 0 to (LngCount[lat]-1) using
LC = LngCount[latCode];
lngCode = (int)(LC * (lng/(2*M_PI) + 0.5) + 0.5) % LC;
  • Besides LngCount[latCode], also store the sum of LngCount[i] with i < latCode as LatBase[latCode]; encode the direction as
dirCode = LatBase[latCode] + lngCode;
  • For decoding, a simple lookup from a precomputed list of directions could be used (2^15 entries, i.e. one hemisphere, will suffice). To conserve space, direction vectors could be scaled by (2^N-1) and stored as (N+1)-bit signed integer triples rather than floating point values; due to the limited precision of the lat/long information, 8 bits per coordinate might be enough, giving a table size of 96k. A full double-precision table would require 786k instead.
275Light sourceDefinite Bug3.70 RC7Very LowLowcircular area lights exhibit anisotropyTracked on GitHub
50%
Future release Task Description

circular area lights exhibit some anisotropy, being brighter along the diagonals than on average, as can be demonstrated with the following scene:

//+w800 +h800
#version 3.7;
global_settings{assumed_gamma 1}
plane{-z,-10 pigment{rgb 1} finish{ambient 0 brilliance 0}}
disc{0,z,10000,0.5}
camera{orthographic location z look_at 10*z up y*12 right x*12}
light_source{-10*z rgb 10 area_light 10*x 10*y 257 257 adaptive 4 circular}
301OtherDefinite Bug3.70 RC7Very LowLowFallback to default image size causes wrong values to b...Tracked on GitHub
50%
Task Description

When resolution is not specified (neither via POVRAY.INI nor via QUICKRES.INI nor via command line or custom .ini file), random values are displayed for image resolution in the Image Output Options message output. (The actual render will be performed at the default size of 160×120 pixels though.)

302OtherPossible Bug3.70 RC7Very LowLowconfusing error message when .ini file cannot be parsedTracked on GitHub
0%
Task Description

When a command-line parameter in an .ini file cannot be parsed (such as “+a.3”), POV-Ray reports a “Problem with setting”, quoting the command line, rather than indicating that the problem occurred in an .ini file. This leads the user to think that the problem is with the command line itself, unnecessarily confusing him.

99Refactoring/CleanupUnimp. Feature/TODO3.70 beta 36DeferVery LowRefactor engine (front- & back-end) code for Unicode su...Tracked on GitHub
0%
Future release Task Description

Front- & Back-end code should be refactored for full Unicode support in scene files and strings.

303OtherDefinite Bug3.70 RC7DeferVery Lowwrong bit depth reported for OpenEXR file formatTracked on GitHub
0%
Task Description

When using OpenEXR output file format, POV-Ray erroneously reports it as “24 bpp EXR” in the message output, while in fact it generates a 3×16 = 48 bpp file.

 238 Parser/SDLPossible Bug3.70 RC4Very LowHigh Error during #read causes file to be kept open Closed
100%
3.70 RC7 Task Description

Consider the following script:

  #fopen F "foo.txt" read
  #read (F, Foo)
  #debug concat ("'", Foo, "'\n")
  #fclose F

Now assume that foo.txt erroneously contains unquoted text (which will result in a parse error):

  Blah

When the error is reported, POV-Ray for Windows will helpfully open foo.txt, but any attempt to save a corrected version of foo.txt will fail until you exit the POV-Ray GUI, presumably because foo.txt is not properly closed by the parser.

 249 Parser/SDLDefinite Bug3.70 RC6Very LowLow UTF-8 files with BOM not accepted Closed
100%
3.70 RC7 Task Description

POV-Ray fails to accept UTF-8 encoded files with a leading Byte Order Mark.

According to the code it was intended to recognize a leading BOM (or, more precisely, leading non-ASCII code sequences) and automatically switch to UTF-8, so this must be considered a bug rather than a missing feature.

 266 FrontendDefinite Bug3.70 RC6Very LowLow command line options in ini files don't accept quoted s ...Closed
100%
3.70 RC7 Task Description

Quoted strings as parameters to command-line options work on the command line but not in INI files; e.g.:

+i"test.pov"

Root cause has already been identified (actually the problem was found during code inspection) and a fix is under way.

 262 Setup/InstallDefinite Bug3.70 RC6Very LowLow sources are being compiled twice on Linux Closed
100%
3.70 release Task Description

When running make on Linux, the backend source files (and possibly others?) are apparently compiled twice: first from the .../source/backend/ directory, and another time from the .../source/ directory. As an example, here are the corresponding lines for sphsweep.cpp:

g++ -DHAVE_CONFIG_H -I. -I../.. -I../.. -I../../source -I../../source -I../../source/base -I../../unix -I../../vfe 
-I../../vfe/unix -pthread -I/usr/include/OpenEXR    -pthread -I/usr/include  -pipe -Wno-multichar -Wno-write-strin
gs -fno-enforce-eh-specs -s -O3 -ffast-math -pthread -MT sphsweep.o -MD -MP -MF .deps/sphsweep.Tpo -c -o sphsweep.
o `test -f 'shape/sphsweep.cpp' || echo './'`shape/sphsweep.cpp
g++ -DHAVE_CONFIG_H -I. -I..  -I.. -I../source/backend -I../source/base -I../source/frontend -I../unix -I../vfe -I.
./vfe/unix -pthread -I/usr/include/OpenEXR    -pthread -I/usr/include  -pipe -Wno-multichar -Wno-write-strings -fno
-enforce-eh-specs -s -O3 -ffast-math -pthread -MT sphsweep.o -MD -MP -MF .deps/sphsweep.Tpo -c -o sphsweep.o `test 
-f 'backend/shape/sphsweep.cpp' || echo './'`backend/shape/sphsweep.cpp

This is especially annoying on platforms that are rather slow at compiling.

 271 Texture/Material/FinishDefinite Bug3.70 RC6DeferLow filter affects object's own brightness in an improper w ...Closed
100%
3.70 release Task Description

The following scene has four spheres with different pigment color & filter settings:

- Left: filter 1
- Right: filter 0

- Top: red 0.0 green 0.5 blue 1.0
- Bottom: red 0.00 green 0.05 blue 0.10 (10% of the above)

Background is set to black, so that we only see the diffuse component of the object’s effective color.

Theoretically, both left spheres should be invisible, as they are fully transmissive (with a filtering effect), but apparently with a high filter setting, reducing an object’s pigment color actually increases the object’s effective diffuse color.

//+w600 +h600

global_settings{ assumed_gamma 1.0 }

camera {
  orthographic
  location  <0,0,-10>
  right 4*x
  up 4*y
  look_at   <0,0,0>
}

light_source{<10,10,-10> color rgb 1 parallel }

background { color rgb 0 }

default {
  finish {
    ambient 0
    diffuse 1
    specular 0
    phong 0
    reflection { 0.0 }
  }
}


sphere { <-1, 1, 0>, 0.8 texture { pigment { color rgb <0,0.5,1.0> filter 1.0 } } }
sphere { < 1, 1, 0>, 0.8 texture { pigment { color rgb <0,0.5,1.0> filter 0.0 } } }

sphere { <-1,-1, 0>, 0.8 texture { pigment { color rgb <0,0.5,1.0>*0.1 filter 1.0 } } }
sphere { < 1,-1, 0>, 0.8 texture { pigment { color rgb <0,0.5,1.0>*0.1 filter 0.0 } } }

This bug has been around in 3.6 already.

 274 Subsurface ScatteringDefinite Bug3.70 RC7Very LowLow light source fading doesn't work properly with area_ill ...Closed
100%
3.70 release Task Description

When using fade_distance and fade_power in combination with area_illumination, the light source fading is not applied to materials with subsurface scattering; see the following code for an example:


#version 3.7;
global_settings {
  assumed_gamma 1.0
  mm_per_unit 10
  subsurface { samples 200,20 }
}

camera {
  right x*image_width/image_height
  angle 30
  location  <0,1.5,-4>
  look_at   <0,0,0>
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

plane {
  y, 0
  texture {
    pigment {
      checker
      color rgb <1.0, 0.8, 0.6>
      color rgb <1.0, 0.0, 0.0>
      scale 0.5
    }
  }
}

light_source {
  <50,50,50>
  color rgb 30
  area_light 5*x,5*y,17,17 adaptive 1 jitter circular orient
  area_illumination on
  fade_distance 10
  fade_power 2
}

cylinder {
  <0,0,0>, <0,0.2,0> 1
  texture {
    pigment { color rgb 1 }
    finish {
      ambient 0
      diffuse 0.7
      specular albedo 0.3
      reflection { 0.3 fresnel }
      conserve_energy
      subsurface { translucency 0.1 }
    }
  }
  interior { ior 1.5 }
}

sphere {
  <0,0.4,0>, 0.2
  texture {
    pigment { color rgb <1,0.6,0.0> }
    finish {
      ambient 0
      diffuse 0.0
      specular albedo 0.8 metallic
      reflection { 1.0 metallic }
      conserve_energy
    }
  }
}

 304 Parser/SDLDefinite Bug3.70 RC7Very LowLow #for-loop may fail to perform last iteration Closed
100%
3.70 release Task Description

Using an end value of 1048576 or larger in a #for loop will cause the last iteration to be skipped, as can be demonstrated by the following code:

#declare N = 2000000;
#debug concat(”N = “,str(N, 0,50),”\n”)
#debug concat(”N-5 = “,str(N-5,0,50),”\n\n”)
#for (I, N-5, N, 1)

#debug concat("I   = ",str(I,0,50),"\n")

#end

(The limit was observed with a Win64 build; other builds may exhibit other limits or might even work fine, depending on the floating point engine used.)

As this limit is still far below the numeric precision limit, and a corresponding #while loop works fine with much higher values, this must be considered a bug rather than an inevitable limitation.

The bug can be tracked down to a faulty condition in tokenize.cpp, Parser::Parse_Directive(), CASE(END_TOKEN), case FOR_COND:

    if ( ((Step > 0) && (*CurrentPtr >= End + EPSILON)) ||
         ((Step < 0) && (*CurrentPtr <= End - EPSILON)) )

which should instead be:

    if ( ((Step > 0) && (*CurrentPtr > End + EPSILON)) ||
         ((Step < 0) && (*CurrentPtr < End - EPSILON)) )
 315 Geometric PrimitivesDefinite Bug3.70 releaseVery LowLow inverse keyword does not work properly with quadrics Closed
100%
3.71 release Task Description

As the following scene demonstrates, the “inverse” keyword produces unexpected results with quadrics.

Left: a sphere primitive as reference
Right: a sphere-shaped quadric primitive (sphere-shaped)

Top: plain
Bottom: inverse

The objects are clipped in half to better demonstrate the effect. Regular texture is shown in white, interior_texture in red; the surface normal of a selected point (blue) as returned by trace() is shown in green.

Note how the sphere’s surface normal, as well as the textures, are flipped when “inverse” is used (this is the intended standard behaviour of all objects), while the quadric’s normal and textures erroneously remain uchanged.

// +w800 +h600

#version 3.7;

global_settings{ assumed_gamma 1.0 }

#default{ finish { ambient 0.1 diffuse 0.9 specular 0.5 }} 

camera {
  perspective
  angle 40
  right     x*image_width/image_height
  location  <0,0,-10>
  look_at   <0,0,0>
}

light_source{ < 1000,3000,-3000> color rgb 1 }

background { color rgb 0.5 }

#declare T_White = texture { pigment { color rgb   1 } }
#declare T_Red   = texture { pigment { color red   1 } }
#declare T_Green = texture { pigment { color green 1 } }
#declare T_Blue  = texture { pigment { color blue  1 } }

#declare TopLeft     = sphere { 0, 1 }
#declare BottomLeft  = sphere { 0, 1 inverse }

#declare TopRight    = quadric { <1,1,1>, <0,0,0>, <0,0,0>, -1 }
#declare BottomRight = quadric { <1,1,1>, <0,0,0>, <0,0,0>, -1 inverse }

#macro Mac(Obj, P, D)
  union {
    #local N = <0,0,0>;
    #local O = <-0.6,0.4,-10>;
    #local Q = trace(Obj, O, D, N);
    #if (vlength(N) > 0)
      sphere { Q, 0.05 texture { T_Blue } }
      cylinder { Q, Q + N, 0.02 texture { T_Green } }
    #else
      cylinder { O, O + D*10000, 0.02 texture { T_Red } }
    #end
    object { Obj texture { T_White } interior_texture { T_Red } clipped_by { box { <-1,-1,-1>, <0,1,1> rotate y*30 } } }
    translate P
  }
#end

Mac(TopLeft,     <-1.2, 1.2, 0>, z)
Mac(TopRight,    < 1.2, 1.2, 0>, z)
Mac(BottomLeft,  <-1.2,-1.2, 0>, z)
Mac(BottomRight, < 1.2,-1.2, 0>, z)
 316 Geometric PrimitivesDefinite Bug3.70 releaseVery LowLow inverse keyword does not work properly with fractals Closed
100%
3.71 release Task Description

As the following scene demonstrates, the “inverse” keyword produces unexpected results with fractals.

Left: a sphere primitive as reference
Right: a julia fractal

Top: plain
Bottom: inverse

The objects are clipped in half to better demonstrate the effect. Regular texture is shown in white, interior_texture in red; the surface normal of a selected point (blue) as returned by trace() is shown in green.

Note how the sphere’s surface normal, as well as the textures, are flipped when “inverse” is used (this is the intended standard behaviour of all objects), while the fractal’s normal and textures erroneously remain uchanged.


// +w800 +h600

#version 3.7;

global_settings{ assumed_gamma 1.0 }

#default{ finish { ambient 0.1 diffuse 0.9 specular 0.5 }} 

camera {
  perspective
  angle 40
  right     x*image_width/image_height
  location  <0,0,-10>
  look_at   <0,0,0>
}

light_source{ < 1000,3000,-3000> color rgb 1 }

background { color rgb 0.5 }

#declare T_White = texture { pigment { color rgb   1 } }
#declare T_Red   = texture { pigment { color red   1 } }
#declare T_Green = texture { pigment { color green 1 } }
#declare T_Blue  = texture { pigment { color blue  1 } }

#declare TopLeft     = sphere { 0, 1 }
#declare BottomLeft  = object { TopLeft inverse }

#declare TopRight    = julia_fractal{ <-0.083,0.0,-0.83,-0.025> quaternion sqr max_iteration 8 precision 20 scale 0.9 }
#declare BottomRight = object { TopRight inverse }

#macro Mac(Obj, P, D)
  union {
    #local N = <0,0,0>;
    #local O = <-0.6,0.4,-10>;
    #local Q = trace(Obj, O, D, N);
    #if (vlength(N) > 0)
      sphere { Q, 0.05 texture { T_Blue } }
      cylinder { Q, Q + N, 0.02 texture { T_Green } }
    #else
      cylinder { O, O + D*10000, 0.02 texture { T_Red } }
    #end
    object { Obj texture { T_White } interior_texture { T_Red } clipped_by { box { <-2,-2,-2>, <0,2,2> rotate y*30 } } }
    translate P
  }
#end

Mac(TopLeft,     <-1.2, 1.2, 0>, z)
Mac(TopRight,    < 1.2, 1.2, 0>, z)
Mac(BottomLeft,  <-1.2,-1.2, 0>, z)
Mac(BottomRight, < 1.2,-1.2, 0>, z)
 318 Texture/Material/FinishDefinite Bug3.70 releaseVery LowLow method 3 (default) scattering media is too bright & cau ...Closed
100%
3.71 release Task Description

The following scene demonstrates how media sampling method 3 gives inaccurate results with scattering media.

The scene shows four spheres with uniform media, using (left to right) sampling methods 1, 2 and 3 with default settings, and sampling method 3 with high minimum sample count, respectively.

Note how changing the sample count significantly affects the result, despite the media being uniform.

Code analysis shows that the root cause is an underestimation of the extinction effect on the light scattered by the media, corresponding in order of magnitude to half the distance between mandatory samples (as defined by minimum sample count).

The effect also leads to visible artifacts when nesting hollow objects inside the media, as can be demonstrated by un-commenting the four smaller spheres.

#version 3.7;

camera {
  perspective angle 25
  location  <0.0 , 0.0 ,-20.0>
  right     x*image_width/image_height
  look_at   <0.0 , 0.0 , 0.0>
}

light_source {
  <0,3000,-3000> color rgb 1
}

background { color rgb 0.5 }

plane {
  <0,1,0>, -1
  texture { pigment { checker color rgb<1,1,1>*1.2 color rgb<0.25,0.15,0.1>*0 } }
}

#declare T_Transparent = texture {
  pigment { color rgbt <1,1,1,1> } finish { diffuse 1 }
}

sphere { <-3,0,0>, 1.00 
  texture { T_Transparent }
  hollow
  interior {
    media {
      scattering { 1 color rgb 2 extinction 1 }
      method 1
    }
  }
}

sphere { <-1,0,0>, 1.00 
  texture { T_Transparent }
  hollow
  interior {
    media {
      scattering { 1 color rgb 2 extinction 1 }
      method 2
    }
  }
}

sphere { <1,0,0>, 1.00 
  texture { T_Transparent }
  hollow
  interior {
    media {
      scattering { 1 color rgb 2 extinction 1 }
      method 3
    }
  }
}

sphere { <3,0,0>, 1.00 
  texture { T_Transparent }
  hollow
  interior {
    media {
      scattering { 1 color rgb 2 extinction 1 }
      method 3
      samples 100
    }
  }
}

/*
sphere { <-3,0,0>,0.8 texture { T_Transparent } hollow }
sphere { <-1,0,0>,0.8 texture { T_Transparent } hollow }
sphere { < 1,0,0>,0.8 texture { T_Transparent } hollow }
sphere { < 3,0,0>,0.8 texture { T_Transparent } hollow }
*/
 51 Parser/SDLDefinite Bug3.70 beta 32Very LowCritical POV-Ray crashes hard on missing parenthesis Closed
100%
3.70 beta 35 Task Description

The following (bogus) SDL code causes POV-Ray 3.7 beta to crash hard with an access violation:

#include "fubar.inc"
Bar(42)
#macro FooBar() #end
//fubar.inc
#macro Foo(Fnord) #end
#macro Bar(Ignord) Foo(23 #end
 104 Image formatDefinite Bug3.70 beta 37MediumCritical Output file gamma broken for File_Gamma=1.0 Closed
100%
3.70 beta 37a Task Description

Setting File_Gamma=1.0 produces unexpectedly bright output files for most output file formats, as if File_Gamma was set to 2.2 instead.

The underlying problem is a bug that, when File_Gamma is set to exactly 1.0, causes the encoding gamma function to be undefined, which was not meant to happen in current versions, and instead was reserved for future versions to signal that a file-format-specific default encoding gamma should be used. The image file output handlers already support this, most of them choosing the sRGB transfer function, giving roughly the same output as setting File_Gamma=2.2.

As a preliminary workaround, users may want to set File_Gamma=1.02 (any value smaller than 0.99 or greater than 1.01 should do).

 95 PhotonsDefinite Bug3.70 beta 36LowHigh Photons are over-attenuated by semi-transparent surface ...Closed
100%
3.70 beta 37 Task Description

The code to attenuate transmitted photons according to surface texture was apparently duplicated during refactoring of the source code for version 3.7. Behavior has changed from 3.6 to 3.7 (beta.36) accordingly, as can be demonstrated with the following scene:

global_settings {
  assumed_gamma 1.0
  max_trace_level 10
  photons { spacing 0.02 }
}

camera {
  right x*image_width/image_height
  location  <0,2.6,-10>
  look_at   <0,0.75,0>
}

light_source {
  <500,300,150>
  color rgb 1.3
  photons {
    refraction on
    reflection on
  }
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

plane {
  y, 0
  texture { pigment { color rgb <1.0, 0.8, 0.6> } }
}

#declare M_Glass=
material {
  texture {
    pigment {rgbt 1}
    finish {
      ambient 0.0
      diffuse 0.05
      specular 0.6
      roughness 0.005
      reflection { 0.1, 1.0 fresnel on }
      conserve_energy
    }
  }
  interior {
    ior 1.5
    fade_power 1001
    fade_distance 0.9
    fade_color <0.5,0.8,0.6>
  }
}

#declare M_PseudoGlass2=
material {
  texture {
    pigment {rgbf <0.8,0.2,0.2,0.8>}
    finish {
      ambient 0.0
      diffuse 0.05
      specular 0.6
      roughness 0.005
      reflection { 0.1, 1.0 fresnel on }
      conserve_energy
    }
  }
  interior {
    ior 1.0
  }
}

sphere {
  <1.1,1,-1.3>, 1
  material { M_Glass }
  photons {
    target 1.0
    refraction on
    reflection on
  }
}

box {
  <2.4,0,-2.3>, <2.6,4,0.3>
  material { M_PseudoGlass2 }
  photons { target 1.0 refraction on reflection on }
}

 113 Texture/Material/FinishDefinite Bug3.70 beta 37aLowHigh Multi-layered reflections broken Closed
100%
3.70 beta 38 Task Description

Reflections in multi-layered textures are broken in 3.7 betas, as can be demonstrated with the following scene showing two reflective hemispheres on a checkered plane:

camera {
  location  <1.0, 0.5, -4.0>
  direction 1.5*z
  right     x*image_width/image_height
  look_at   <0.0, 0.0,  0.0>
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

light_source {
  <0, 0, 0>            // light's position (translated below)
  color rgb <1, 1, 1>  // light's color
  translate <-30, 30, -30>
}

default {
 finish { diffuse 0 ambient 0 specular 0 }
}

// ----------------------------------------

plane {               // checkered floor
  y, -1
  texture
  {
    pigment { checker color rgb 1 color blue 1 }
    finish{ diffuse 0.8 ambient 0.1 }
  }
}

// left hemisphere
intersection {
  sphere { 0, 1 }
  plane { x, -0.002 }
  texture {
    pigment { color rgb 1 }
    finish{ reflection { 0.5 } }
  }
  texture {
    pigment { color rgbt 1 }
    finish{ reflection { 0.4 } }
  }
  texture {
    pigment { color rgbt 1 }
    finish{ reflection { 0.1 } }
  }
}

// right hemisphere
intersection {
  sphere { 0, 1 }
  plane { -x, -0.002 }
  texture {
    pigment { color rgb 1 }
    finish{ reflection { 1.0 } }
  }
}

Note that the reflection parameters of the left, multi-layered hemisphere sum up to 1.0, i.e. the same value as used in the single layer in the right hemisphere.

The first attached file (test_3.6.2.png), rendered with POV-Ray 3.6.2, shows the expected output: Both hemispheres appear to have the same reflectivity.

The second attached file (test_3.7.0.beta37a.png), rendered with POV-Ray 3.7.0.beta.37a, shows a much brighter left (multi-layered) sphere.

As it turns out, in order to get the expected result with POV-Ray 3.7.0.beta.37a, the reflectivity of each layer must be divided by 3, 2 and 1, respectively (which obviously does not sum up to 1.0):

  ...
  texture {
    pigment { color rgb 1 }
    finish{ reflection { 0.5 / 3 } }
  }
  texture {
    pigment { color rgbt 1 }
    finish{ reflection { 0.4 / 2 } }
  }
  texture {
    pigment { color rgbt 1 }
    finish{ reflection { 0.1 / 1 } }
  }
  ...
 182 Texture/Material/FinishDefinite Bug3.70 beta 40LowHigh multi-textured blobs in intersections / differences bro ...Closed
100%
3.70 beta 41 Task Description

Multi-textured blobs are broken with 3.7 beta 40 when used inside an intersection, as can be demonstrated by the following scene:

#default { texture { pigment { rgb 1 } } }

camera {
  right x*image_width/image_height
  location  <0,1.5,-4>
  look_at   <0,1,0>
}

light_source { <500,500,-500> color rgb 1 }

difference { blob {
  threshold 0.6
  sphere { < 0.75,   0,    0>, 1, 1 texture { pigment { color red 1 } } }
  sphere { <-0.375,  0.65, 0>, 1, 1 texture { pigment { color green 1 } } }
  sphere { <-0.375, -0.65, 0>, 1, 1 }
} }

With POV-Ray 3.7.0 beta 40, the entire blob is rendered with the default texture.

The same problem can be seen with “difference” or “merge” instead of “intersection”.

Omitting the CSG “envelope”, using “union”, or assigning the blob to a variable first and then using it inside an intersection, will yield the expected result.

POV-Ray 3.62 renders all variants as expected.

According to initial analysis, the problem appears to be caused by the dual use of the “MULTITEXTURE_FLAG”, which is used in CSG to indicate use of the “cutaway_textures” feature, and in blobs to indicate per-element texturing. (The same flag is also used in meshes to indicate per-face or per-vertex texturing, so similar problems are to expected there.)

My proposal is to use an entirely separate flag for the “cutaway_textures” feature (the blob and mesh can safely continue to share the MULTITEXTURE_FLAG).

 270 OtherDefinite Bug3.70 releaseMediumHigh render abort-continue (+C) sometimes skips blocks Closed
100%
Task Description

When aborting a render when there are unfinished blocks among finished ones, under certain conditions some of those blocks are skipped when continuing the render later.

 10 Parser/SDLFeature Request3.70 beta 32Very LowMedium Add support for specifying input images' gamma pre-corr ...Closed
100%
3.70 beta 40 Task Description

Input image files may have been created with gamma pre-correction for some specific target gamma, which may vary from image to image. Some file formats like PNG or HDR support embedding gamma pre-correction information in the image file, but this information may be missing or faulty, and some formats don’t support it at all. Additionally, it may be desirable to tamper with an input image’s gamma for artistic reasons.

Therefore, I suggest adding a means to explicitly specify input images’ originally intended target gamma on a per-image basis, like:

image_map { jpeg "MyImage.jpg" assumed_gamma 1.8 }
 39 DistributionDefinite Bug3.70 beta 32Very LowMedium "cats" and "life" sample scenes broken Closed
100%
3.70 release Task Description

The following files were garbled in changelist #4648 by stripping all line terminators, making the files unusable:

  • .../scenes/advanced/cats/cattext.inc
  • .../scenes/animations/life/blink4.inc
  • .../scenes/animations/life/walker.inc

Line terminators of these files were already problematic in previous versions of the file, having been CR-only.

The following files changed with #4648 should be reviewed closely as well, as they were previously CR-only, too, and at least some of them exhibit some peculiarities regarding line and/or file terminators:

  • .../scenes/animations/pentmap/pentmap.ini
  • .../scenes/animations/pentmap/pentmap.pov
  • .../scenes/animations/slinky/slnk.ini
  • .../scenes/incdemo/metals/metals.doc
  • .../scenes/incdemo/stones/stones.doc
  • .../scenes/incdemo/woods/morewood.doc
  • .../scenes/incdemo/woods/woods.doc
  • .../scenes/textures/pigments/skies/skies.doc
 57 Texture/Material/FinishDefinite Bug3.70 beta 34Very LowMedium Compressed TIFF image_map renders all transparent Closed
100%
Task Description

The attached TIFF file was created with IC using compression. When used in an image_map, POV-Ray 3.7.0.beta.34 on Windows XP x64 renders the image all transparent, while POV-Ray 3.6.2 renders the file fine. The same effect can be seen with LZW-compressed TIFF files created with Adobe Photoshop 6.0.

Uncompressed TIFF files created with either IC or Photoshop render fine in both versions of POV-Ray.

Stepping through the code of POV-Ray 3.7.0 shows that the same code path is taken regardless of compression, but the libtiff library returns different alpha channel values, indicating a problem in that library. POV-Ray 3.7 still uses libtiff 3.6.1, whereas the POV-Ray 3.6 branch has been updated to libtiff 3.8.2, which according to the change history includes a few alpha-related changes.

 61 OtherDefinite Bug3.70 beta 34LowMedium Dispersion does not give proper results Closed
100%
Task Description

Source code inspection during examination of issues with the scene published at http://povray.sitewww.ch/?p=177 show the following issues with current (beta.34) implementation of dispersion in POV-Ray 3.7:

  • The same adjustment to the IOR that is applied at the very first dispersion interface is erroneously applied to all subsequent interfaces.
  • As an exception, dispersion adjustment is erroneously not applied to any interface defined by the surface of a non-dispersing object embedded into a dispersing object.

While this still allows to use dispersion for artistic effect, it is neither physically realistic, nor does it match 3.6 behavior.

 93 PhotonsDefinite Bug3.70 beta 36Very LowMedium Photons are unnaturally amplified by pass_through objec ...Closed
100%
3.70 release Task Description

The following scene shows how photons are “boosted” by pass_through objects; removing one of the boxes will reduce the effect; the effect can be seen with 3.6 as well as current betas:

global_settings {
  max_trace_level 10 // makes a difference!
  photons { spacing 0.02 }
}

camera {
  right x*image_width/image_height
  location  <0,2.6,-10>
  look_at   <0,0.75,0>
}

light_source {
  <500,500,150>
  color rgb 1.3
  photons {
    refraction on
    reflection on
  }
}

sky_sphere {
  pigment {
    gradient y
    color_map {
      [0.0 rgb <0.6,0.7,1.0>]
      [0.7 rgb <0.0,0.1,0.8>]
    }
  }
}

plane {
  y, 0
  texture { pigment { color rgb <1.0, 0.8, 0.6> } }
}

#declare M_Glass=
material {
  texture {
    pigment {rgbt 1}
    finish {
      ambient 0.0
      diffuse 0.05
      specular 0.6
      roughness 0.005
      reflection { 0.1, 1.0 fresnel on }
      conserve_energy
    }
  }
  interior {
    ior 1.5
    fade_power 1001
    fade_distance 0.9
    fade_color <0.5,0.8,0.6>
  }
}


sphere {
  <1.1,1,-1.3>, 1
  material { M_Glass }
  photons {
    target 1.0
    refraction on
    reflection on
  }
}

cylinder {
  <-1.2,0.01,0.8>, <-1.2,2.5,0.8>, 1
  material { M_Glass }
  photons {  // photon block for an object
    target 1.0
    refraction on
    reflection on
  }
}

box {
  <2.4,0,-2.3>, <2.6,4,-0.3>
  material { M_Glass }
  photons { pass_through }
}

box {
  <2.9,0,-2.3>, <3.1,4,-0.3>
  material { M_Glass }
  photons { pass_through }
}
Showing tasks 1 - 50 of 87 Page 1 of 21 - 2 -

Available keyboard shortcuts

Tasklist

Task Details

Task Editing