n |
Sets screen height to n pixels |
n |
Sets screen width to n pixels |
n |
Same as |
n |
Same as |
These switches set the height and width of the image in pixels. This specifies the image size for file output. The preview display, if on, will generally attempt to pick a video mode to accommodate this size but the display settings do not in any way affect the resulting file output.
n |
Set first column to n pixels |
0.n |
Set first column to n percent of width |
n or +SC 0.n |
Same as |
n |
Set first row to n pixels |
0.n |
Set first row to n percent of height |
n or +S n |
Same as |
0.n or +S 0.n |
Same as |
n |
Set last column to n pixels |
0.n |
Set last column to n percent of width |
n or +EC 0.n |
Same as |
n |
Set last row to n pixels |
0.n |
Set last row to n percent of height |
n or +E n |
Same as |
0.n or +E 0.n |
Same as |
When doing test rendering it is often convenient to define a small, rectangular sub-section of the whole screen so you can quickly check out one area of the image. The Start_Row
, End_Row
, Start_Column
and End_Column
options allow you to define the subset area to be rendered. The default values are the full size of the image from (1,1) which is the upper left to (w,h) on the lower right where w and h are the Width=
n and Height=
n values you have set.
Note if the number specified is greater than 1 then it is interpreted as an absolute row or column number in pixels. If it is a decimal value between 0.0 and 1.0 then it is interpreted as a percent of the total width or height of the image. For example: Start_Row=0.75
and Start_Column=0.75
starts on a row 75% down from the top at a column 75% from the left. Thus it renders only the lower-right 25% of the image regardless of the specified width and height.
The +SR
, +ER
, +SC
and +EC
switches work in the same way as the corresponding INI-style settings for both absolute settings or percentages. Early versions of POV-Ray allowed only start and end rows to be specified with +S
n and +E
n so they are still supported in addition to +SR
and +ER
.
bool |
Turn test for user abort on/off |
|
Turn test abort on |
|
Turn test abort off |
n |
Set to test for abort every n pixels |
n |
Set to test for abort every n pixels on |
n |
Set to test for abort off (in future test every n pixels) |
On some operating systems once you start a rendering you must let it finish. The Test_Abort=on
option or +X
switch causes POV-Ray to test the keyboard for keypress. If you have pressed a key, it will generate a controlled user abort. Files will be flushed and closed but only data through the last full row of pixels is saved. POV-Ray exits with an error code 2 (normally POV-Ray returns 0 for a successful run or 1 for a fatal error).
When this option is on, the keyboard is polled on every line while parsing the scene file and on every pixel while rendering. Because polling the keyboard can slow down a rendering, the Test_Abort_Count=
n option or +X
n switch causes the test to be performed only every n pixels rendered or scene lines parsed.
bool |
Sets continued trace on/off |
|
Sets continued trace on |
|
Sets continued trace off |
file |
Generate an INI file to file |
true |
Generate |
false |
Turn off generation of previously set |
file |
Same as |
If you abort a render while it's in progress or if you used the End_Row
option to end the render prematurely, you can use Continue_Trace=on
or +C
option to continue the render later at the point where you left off. This option reads in the previously generated output file, displays the partial image rendered so far, then proceeds with the ray-tracing. This option cannot be used if file output is disabled with Output_to_file=off
or -F
.
The Continue_Trace
option may not work if the Start_Row
option has been set to anything but the top of the file, depending on the output format being used.
POV-Ray tries to figure out where to resume an interrupted trace by reading any previously generated data in the specified output file. All file formats contain the image size, so this will override any image size settings specified. Some file formats (namely TGA and PNG) also store information about where the file started (i. e. +SC
n and +SR
n options), alpha output +UA
, and bit-depth +FN
n, which will override these settings. It is up to the user to make sure that all other options are set the same as the original render.
The Create_Ini
option or +GI
switch provides an easy way to create an INI file with all of the rendering options, so you can re-run files with the same options, or ensure you have all the same options when resuming. This option creates an INI file with every option set at the value used for that rendering. This includes default values which you have not specified. For example if you run POV-Ray with...
POVRAY +Isimple.pov MYOPTS +GIrerun.ini MOREOPTS
POV-Ray will create a file called rerun.ini
with all of the options used to generate this scene. The file is not written until all options have been processed. This means that in the above example, the file will include options from both myopts.ini
and moreopts.ini
despite the fact that the +GI
switch is specified between them. You may now re-run the scene with...
POVRAY RERUN
or resume an interrupted trace with
POVRAY RERUN +C
If you add other switches with the rerun.ini
reference, they will be included in future re-runs because the file is re-written every time you use it.
The Create_Ini
option is also useful for documenting how a scene was rendered. If you render waycool.pov
with Create_Ini=on
then it will create a file waycool.ini
that you could distribute along with your scene file so other users can exactly re-create your image.
bool |
Turns graphic display on/off |
|
Turns graphic display on |
|
Turns graphic display off |
x |
Set video mode to x; does not affect on/off |
x |
Set display on; Set mode to x |
x |
Set display off; but for future use mode x |
y |
Set display palette to y; does not affect on/off |
xy |
Set display on; Set mode x; Set palette y |
xy |
Set display off; use mode x, palette y in future |
n.n |
Sets the display gamma to n.n |
The Display=on
or +D
switch will turn on the graphics display of the image while it is being rendered. Even on some non-graphics systems, POV-Ray may display an 80 by 24 character "ASCII-Art" version of your image. Where available, the display may be full, 24-bit true color. Setting Display=off
or using the -D
switch will turn off the graphics display which is the default.
The Video_Mode=
x option sets the display mode or hardware type chosen where x is a single digit or letter that is machine dependent. Generally Video_Mode=0
means the default or an auto-detected setting should be used. When using switches, this character immediately follows the switch. For example the +D0
switch will turn on the graphics display in the default mode.
The Palette=
y option selects the palette to be used. Typically the single character parameter y is a digit which selects one of several fixed palettes or a letter such G
for gray scale, H
for 15-bit or 16-bit high color or T
for 24-bit true color. When using switches, this character is the 2nd character after the switch. For example the +D0T
switch will turn on the graphics display in the default mode with a true color palette.
The Display_Gamma=
n.n setting is new with POV-Ray 3.0, and is not available as a command-line switch. The Display_Gamma
setting overcomes the problem of images (whether ray-traced or not) having different brightness when being displayed on different monitors, different video cards, and under different operating systems. Note that the Display_Gamma
is a setting based on your computer's display hardware, and should be set correctly once and not changed. The Display_Gamma
INI setting works in conjunction with the new assumed_gamma
global setting to ensure that POV scenes and the images they create look the same on all systems. See section "Assumed_Gamma" which describes the assumed_gamma
global setting and describes gamma more thoroughly.
While the Display_Gamma
can be different for each system, there are a few general rules that can be used for setting Display_Gamma
if you don't know it exactly. If the Display_Gamma
keyword does not appear in the INI file, POV-Ray assumes that the display gamma is 2.2. This is because most PC monitors have a gamma value in the range 1.6 to 2.6 (newer models seem to have a lower gamma value). Mac has the ability to do gamma correction inside the system software (based on a user setting in the gamma control panel). If the gamma control panel is turned off, or is not available, the default Macintosh system gamma is 1.8. Some high-end PC graphics cards can do hardware gamma correction and should use the current Display_Gamma setting, usually 1.0. A gamma test image is also available to help users to set their Display_Gamma
accurately.
For scene files that do not contain an assumed_gamma
global setting the INI file option Display_Gamma
will not have any affect on the preview output of POV-Ray or for most output file formats. However, the Display_Gamma
value is used when creating PNG format output files, and also when rendering the POV-Ray example files (because they have an assumed_gamma
), so it should still be correctly set for your system to ensure proper results.
bool |
Sets pause when done on/off |
|
Sets pause when done on |
|
Sets pause when done off |
bool |
Set verbose messages on/off |
|
Set verbose messages on |
|
Set verbose messages off |
bool |
Turn draw vistas on/off |
|
Turn draw vistas on |
|
Turn draw vistas off |
On some systems, when the image is complete, the graphics display is cleared and POV-Ray switches back into text mode to print the final statistics and to exit. Normally when the graphics display is on, you want to look at the image awhile before continuing. Using Pause_When_Done=on
or +P
causes POV-Ray to pause in graphics mode until you press a key to continue. The default is not to pause (-P
).
When the graphics display is not used, it is often desirable to monitor progress of the rendering. Using Verbose=on
or +V
turns on verbose reporting of your rendering progress. This reports the number of the line currently being rendered, the elapsed time for the current frame and other information. On some systems, this textual information can conflict with the graphics display. You may need to turn this off when the display is on. The default setting is off (-V
).
The option Draw_Vistas=on
or +UD
was originally a debugging help for POV-Ray's vista buffer feature but it was such fun we decided to keep it. Vista buffering is a spatial sub-division method that projects the 2-D extents of bounding boxes onto the viewing window. POV-Ray tests the 2-D x, y pixel location against these rectangular areas to determine quickly which objects, if any, the viewing ray will hit. This option shows you the 2-D rectangles used. The default setting is off (-UD
) because the drawing of the rectangles can take considerable time on complex scenes and it serves no critical purpose. See section "Automatic Bounding Control" for more details.
n |
Set mosaic preview start size to n |
n |
Same as Preview_Start_Size=n |
n |
Set mosaic preview end size to n |
n |
Same as Preview_End_Size=n |
Typically, while you are developing a scene, you will do many low resolution test renders to see if objects are placed properly. Often this low resolution version doesn't give you sufficient detail and you have to render the scene again at a higher resolution. A feature called "mosaic preview" solves this problem by automatically rendering your image in several passes.
The early passes paint a rough overview of the entire image using large blocks of pixels that look like mosaic tiles. The image is then refined using higher resolutions on subsequent passes. This display method very quickly displays the entire image at a low resolution, letting you look for any major problems with the scene. As it refines the image, you can concentrate on more details, like shadows and textures. You don't have to wait for a full resolution render to find problems, since you can interrupt the rendering early and fix the scene, or if things look good, you can let it continue and render the scene at high quality and resolution.
To use this feature you should first select a Width
and Height
value that is the highest resolution you will need. Mosaic preview is enabled by specifying how big the mosaic blocks will be on the first pass using Preview_Start_Size=
n or +SP
n. The value n should be a number greater than zero that is a power of two (1, 2, 4, 8, 16, 32, etc.) If it is not a power of two, the nearest power of two less than n is substituted. This sets the size of the squares, measured in pixels. A value of 16 will draw every 16th pixel as a 16*16 pixel square on the first pass. Subsequent passes will use half the previous value (such as 8*8, 4*4 and so on.)
The process continues until it reaches 1*1 pixels or until it reaches the size you set with Preview_End_Size=
n or +EP
n. Again the value n should be a number greater than zero that is a power of two and less than or equal to Preview_Start_Size
. If it is not a power of two, the nearest power of two less than n is substituted. The default ending value is 1. If you set Preview_End_Size
to a value greater than 1 the mosaic passes will end before reaching 1*1, but POV-Ray will always finish with a 1*1. For example, if you want a single 8*8 mosaic pass before rendering the final image, set Preview_Start_Size=8
and Preview_End_Size=8.
No file output is performed until the final 1*1 pass is reached. Although the preliminary passes render only as many pixels as needed, the 1*1 pass re-renders every pixel so that anti-aliasing and file output streams work properly. This makes the scene take up to 25% longer than the regular 1*1 pass to render, so it is suggested that mosaic preview not be used for final rendering. Also, the lack of file output until the final pass means that renderings which are interrupted before the 1*1 pass can not be resumed without starting over from the beginning.
Future versions of POV-Ray will include some system of temporary files or buffers which will eliminate these inefficiencies and limitations. Mosaic preview is still a very useful feature for test renderings.
bool |
Sets file output on/off |
|
Sets file output on (use default type) |
|
Sets file output off |
By default, POV-Ray writes an image file to disk. When you are developing a scene and doing test renders, the graphic preview may be sufficient. To save time and disk activity you may turn file output off with Output_to_File=off
or -F
.
x |
Sets file output format to x |
xn |
Sets file output on; sets format x, depth n |
xn |
Sets file output off; but in future use format x, depth n |
bool |
Sets alpha output on/off |
|
Sets alpha output on |
|
Sets alpha output off |
n |
Sets file output bits/color to n |
The default type of image file depends on which platform you are using. MS-DOS and most others default to 24-bit uncompressed Targa. See your platform-specific documentation to see what your default file type is. You may select one of several different file types using Output_File_Type=
x or +F
x where x is one of the following...
|
Compressed Targa-24 format (RLE, run length encoded) |
|
New PNG (portable network graphics) format |
|
Unix PPM format |
|
System-specific such as Mac Pict or Windows BMP |
|
Uncompressed Targa-24 format |
Note that the obsolete +FD
dump format and +FR
raw format have been dropped from POV-Ray 3.0 because they were rarely used and no longer necessary. PPM, PNG, and system specific formats have been added. PPM format images are uncompressed, and have a simple text header, which makes it a widely portable image format. PNG is a new image format designed not only to replace GIF, but to improve on its shortcomings. PNG offers the highest compression available without loss for high quality applications, such as ray-tracing. The system specific format depends on the platform used and is covered in the appropriate system specific documentation.
Most of these formats output 24 bits per pixel with 8 bits for each of red, green and blue data. PNG allows you to optionally specify the output bit depth from 5 to 16 bits for each of the red, green, and blue colors, giving from 15 to 48 bits of color information per pixel. The default output depth for all formats is 8 bits/color (16 million possible colors), but this may be changed for PNG format files by setting Bits_Per_Color=
n or by specifying +FN
n, where n is the desired bit depth.
Specifying a smaller color depth like 5 bits/color (32768 colors) may be enough for people with 8- or 16-bit (256 or 65536 color) displays, and will improve compression of the PNG file. Higher bit depths like 10 or 12 may be useful for video or publishing applications, and 16 bits/color is good for grayscale height field output (See section "Height Field" for details on height fields).
Targa format also allows 8 bits of alpha transparency data to be output, while PNG format allows 5 to 16 bits of alpha transparency data, depending on the color bit depth as specified above. You may turn this option on with Output_Alpha=on
or +UA
. The default is off or -UA
. See section "Using the Alpha Channel" for further details on transparency.
In addition to support for variable bit-depths, alpha channel, and grayscale formats, PNG files also store the Display_Gamma
value so the image displays properly on all systems (see section "Display Hardware Settings"). The hf_gray_16
global setting, as described in section "HF_Gray_16" will also affect the type of data written to the output file.
file |
Sets output file to file |
file |
Same as |
The default output filename is created from the scene name and need not be specified. The scene name is the input name with all drive, path, and extension information stripped. For example if the input file name is c:\povray3\mystuff\myfile.pov
the scene name is myfile
. The proper extension is appended to the scene name based on the file type. For example myfile.tga
or myfile.png
might be used.
You may override the default output name using Output_File_Name=
file or +O
file. For example:
Input_File_Name=myinput.pov Output_File_Name=myoutput.tga
If an output file name of "-" is specified (a single minus sign), then the image will be written to standard output, usually the screen. The output can then be piped into another program or to a GUI if desired.
If the file specified is actually a path or directory or folder name and not a file name, then the default output name is used but it is written to the specified directory. For example:
Input_File_Name=myscene.pov Output_File_Name=c:\povray3\myimages\
This will create c:\povray3\myimages\myscene.tga
as the output file.
bool |
Turn output buffering on/off |
|
Turn output buffering on |
|
Turn output buffering off |
n |
Set output buffer size to n kilobytes. If n is zero, no buffering. If n < system default, the system default is used. |
n |
Turn buffer on, set size n |
n |
Turn buffer off, but for future set size n |
The Buffer_Output
and Buffer_Size
options and the +B
switch allows you to assign large buffers to the output file. This reduces the amount of time spent writing to the disk. If this parameter is not specified, then as each row of pixels is finished, the line is written to the file and the file is flushed. On most systems, this operation ensures that the file is written to the disk so that in the event of a system crash or other catastrophic event, at least a part of the picture has been stored properly and retrievable on disk. The default is not to use any buffer.
The CPU utilization histogram is a way of finding out where POV-Ray is spending its rendering time, as well as an interesting way of generating heightfields. The histogram splits up the screen into a rectangular grid of blocks. As POV-Ray renders the image, it calculates the amount of time it spends rendering each pixel and then adds this time to the total rendering time for each grid block. When the rendering is complete, the histogram is a file which represents how much time was spent computing the pixels in each grid block.
Not all versions of POV-Ray allow the creation of histograms. The histogram output is dependent on the file type and the system that POV-Ray is being run on.
y |
Set histogram type to y (Turn off if type is ' |
y |
Same as |
The histogram output file type is nearly the same as that used for the image output file types in "Output File Type". The available histogram file types are as follows.
|
Comma separated values (CSV) often used in spreadsheets |
|
New PNG (portable network graphics) format grayscale |
|
Unix PPM format |
|
System-specific such as Mac Pict or Windows BMP |
|
Uncompressed Targa-24 format (TGA) |
|
No histogram file output is generated |
Note that +HTC
does not generate a compressed Targa-24 format output file but rather a text file with a comma-separated list of the time spent in each grid block, in left-to-right and top-to bottom order. The units of time output to the CSV file are system dependent. See the system specific documentation for further details on the time units in CSV files.
The Targa and PPM format files are in the POV heightfield format (see "Height Field"), so the histogram information is stored in both the red and green parts of the image, which makes it unsuitable for viewing. When used as a height field, lower values indicate less time spent calculating the pixels in that block, while higher indicate more time spent in that block.
PNG format images are stored as grayscale images and are useful for both viewing the histogram data as well as for use as a heightfield. In PNG files, the darker (lower) areas indicate less time spent in that grid block, while the brighter (higher) areas indicate more time spent in that grid block.
file |
Set histogram name to file |
file |
Same as |
The histogram file name is the name of the file in which to write the histogram data. If the file name is not specified it will default to histgram.ext
, where ext
is based on the file type specified previously. Note that if the histogram name is specified the file name extension should match the file type.
nn.mm |
Set histogram grid to nn by mm |
nn.mm |
Same as |
The histogram grid size gives the number of times the image is split up in both the horizontal and vertical directions. For example
povray +Isample +W640 +H480 +HTN +HS160.120 +HNhistogrm.png
will split the image into 160*120 grid blocks, each of size 4*4 pixels, and output a PNG file, suitable for viewing or for use as a heightfield. Smaller numbers for the grid size mean more pixels are put into the same grid block. With CSV output, the number of values output is the same as the number of grid blocks specified. For the other formats the image size is identical to the rendered image rather than the specified grid size, to allow easy comparison between the histogram and the rendered image. If the histogram grid size is not specified, it will default to the same size as the image, so there will be one grid block per pixel.
Note that on systems that do task-switching or multi-tasking the histogram may not exactly represent the amount of time POV-Ray spent in a given grid block since the histogram is based on real time rather than CPU time. As a result, time may be spent for operating system overhead or on other tasks running at the same time. This will cause the histogram to have speckling, noise or large spikes. This can be reduced by decreasing the grid size so that more pixels are averaged into a given grid block.