「Dev:Py/Scripts/Render/POV-Ray」の版間の差分

提供: wiki
< Dev:Py‎ | Scripts‎ | Render
移動先: 案内検索
 
(1版 をインポートしました)
 
(相違点なし)

2018年6月29日 (金) 04:40時点における最新版

render_povray
Renders scenes with POV-Ray 3.7
UI location Renderer rolldown menu
Usage If POV-Ray 3.7 is installed, activate the addon in the menu File » User Preferences. Choose it as the renderer and render with F12.
Version 0.0.8 Author(s) Campbell Barton, Silvio Falcinelli, Maurice Raybaud, Constantin Rahn
Blender 2.57 License GPL
Category Render Distribution Release
Note(s) After May the 10th 2011, some development to the script limited backwards compatibility: If you set up some files prior to that and always use the latest exporter from SVN. It is advised to run the update script and resave your scene with the new version: get to the search bar with Space and type pov to access this command.


Executable information
File name (Python script)+ POV-Ray 3.7
Current version download https://svn.blender.org/svnroot/bf-extensions/trunk/py/scripts/addons/render_povray/
Python modules Used standard Python modules
External Python Modules or dependencies POV-Ray 3.7 current beta


Warning Both POV-Ray 3.7 and this script are beta.
Links http://povray.org/
Release Log Dev:2.5/Py/Scripts/Render/POV-Ray
Known Issues Currently Important:
  • Packed texture files need to be unpacked.
  • Linked libraries don't work
  • Border-Render crashes Blender


POV-Ray 3.7 Exporter Development

Test files:

Media:regression_and_test_blendfiles.zip

History

This script started as a proof of concept developed by Campbell Barton for the render API introduced with Blender 2.5. It could render most geometry types right from the start by converting them to triangles.

Silvio Falcinelli added support for UV mapping and Maurice Raybaud worked mostly on the shading area.

Constantin Rahn improved formatting and control of output files including the first ability to export animation.

Bastien Montagne improved the overall architecture of the script and its integration with Linux.

What's New:

After May the 10th 2011, some development to the script limited backwards compatibility: If you set up some files prior to that and always use the latest exporter from SVN. It is advised to run the update script and save your scene again with the new version: get to the search bar with Space and type 'pov' to access this command.

Povray 3.7 is now in RC7. Release is imminent and just waiting for the end of the documentation update. Some change to the SSTL syntax will require a refresh of Blender's SSS exporting as soon as POV's next release candidate (whether as the official release or not)is available

Latest Fixes:

Complete List:

http://projects.blender.org/scm/viewvc.php/trunk/py/scripts/addons/render_povray/?root=bf-extensions&view=log


Selective Digest:


-improved world export

-Added texture gamma adjustment ("gamma n.n" keyword per image_map in pov syntax)

-Added a media entry at world level to allow fast atmospheric effects like volume lights

-Lattices made scenes crash the export

-Better matching of blender texture scales and

-Meshes: Some updates of Blender trunk, now subdivided meshes can export

-Added some advanced Radiosity photons and Depth of Field UI controls

-Animations can be exported directly and a clock variable allows to script some more by hand

-Custom replacement code for Materials from Text editor added

Workflow, Architecture and developement Guidelines:

'The idea is two step:

  • to translate Blender Materials and geometry 100 % so users can start quickly from their old Blender scenes and create artwork, form a community

this even, if it requires a little "unnatural" pov approaches.

  • implement every possible native POV feature for Blender to become the first choice interface to pov' this has already started by allowing

the use of custom codes.

POV-Ray specific concepts

POVMindMap.png

object (geometry+material)

Objects are the building blocks of your scene. There are a lot of different types of objects supported by POV-Ray. they are also sometimes called primitives. The mesh object often exported from Blender is just one of the possible primitives supported by POV, but it's one that allows to make the most profitable use of the exporter because a sculpted mesh is easily done in Blender interface and practically impossible to do with POV-Ray alone. The second stage of the exporter's development will allow to use more POV native primitives through Blender interface.

In any case the pov object contains the geometry and can also have the material block, if there is one, at the same hireachical level. This type of construction could be compared to Blender use of "Object Material"

material (interior+texture)

In POV-Ray, there used to be only texture properties inside an object and interior properties such as Index of Refraction could be declared in the same block.


But the developers thought "It is totally illogical to have a ray enter an object with one index or refraction and then recalculate with another index" in the case of multitextured objects.

Nowadays, POV-Ray texture still contains the properties ruling interaction between an object and its environment, such as reflectivity, roughness etc. while Interior stands for internal properties that have an incidence on the light that crosses the surface: index of refraction, media scattering or absorbing light, etc.

For easier reference with a single identifier in a texture library, a wrapper around texture and interior has been created which we call 'material'

texture (pigment+normal+finish)

POV-Ray textures are combinations of pigments, normals, and finishes.

  • Pigment is the color or pattern of colors inherent in the material.
  • Normal is a method of simulating various patterns of bumps, dents, ripples or waves by modifying the surface normal vector.
  • Finish describes the reflective properties of a material.

texture_list

If the texture is not put inside a material statement, it can be put directly inside the geometry of the object, it allows to apply different textures to different parts of the object through a texture list and texture indices assigned per face.

The exporter exploits this feature for meshes with several materials. This type of construction could be compared to Blender's Data material. However, in POV-Ray, all the textures still share one common set of interior properties per object.


What's in a "texture"

pigment / normal

  • color
  • patterns/bitmap

finish

A little different as it can be patterned

Most complex Materials case

Blender materials being able to map alpha, diffuse, normal, specular, specular hardness, specular color

what is impossible in POV: map with various specular color What remains: most complex exported material case

Current implementation

[Mindmap of the most complex datafow]

shader emulation alpha to filter

pigment normal

all this duplicated with min and max specular

May Do List:

If you want to add some fucnctionality or fame to POV exporter, here are a few planned tasks, from the easiest to more complex among which to pick:

  • Create a POV importer;: ideally, it would not be a separate addon, but would just get activated at the same time as the exporter. providing an entry in Blender import menu. but maybe also
    • a special pov primitive in the creation menu?
    • an "import" operator button in the text window somewhere around the custom povcode check box
  • just making nice pictures to provide the scenes to testers would be very usefull. Jeremy Birns Render challenges are a good start for models.
  • adding presets to radiosity in blender interface, their names and settings should imitate the settings of the rad_def include file shipped with POV, but just work over the interface to avoid including the rad_def in the exported pov (an include statement in a pov file slows down parsing/rendering), it's a good example of what an interface like blender can bring to all pov users who are not used to have one.
  • adding pov rainbow object (special primitive)
  • moving atmospheric media from main render property tab to world properties? having all pov properties not too scattered across tabs could be a good thing though... what do you think?
  • write custom materials after globals rather than before as it does now, to allow the use of srgb colors definitions after assumed gamma is already specified
  • repairing vertex colors, broken since bmesh
  • adding procedural texture(s) inside some wrapper "POV" texture available if possible at the same level as the blender procedurals so that we can still have an automatic translation of those from Blender Internal scenes (most of them find some equivalents in pov by only changing the names and some factors for their parameters. In the exported pov code the patterns with its options should be written anywhere a bitmap currently can be written.
  • hair rendering has just been added but not all corner case have been tested, it probably fails a lot also if procedural(s) are added, maybe some color could be derived from it for the hair sphere sweep.
  • smoke support can be added by making Blender write voxel data to a DF3 File


other areas:

  • Exporter should support texture animation. Blender image sequence and current Offset value should be evaluated and then the correct texture would be the selected and written to export. This works in BI and in Cycles.
  • it would be cool to be able to activate compositing for pov render, maybe inspiring from freestyle integration for the code, but the implementation would be best based on BI interface. the only effects we really need since they are so slow in POV are vector blur and defocus for the vector pass, it would necessarily have to run a BI render just before compositing. For the zdepth it could either be made that way as well or using a fog with a white override material in POV to create a zdepth in a previous or subsequent render pass to the main one.
  • repair baking code (mesh camera), currently commented out
  • adding povray 3.7 real time mode (+RTR command line) inspiring from cycles for its interface integration
  • integrating Lightsys or sunpos macro using the sky option of the sun lamp and all necessary additional parameters



OTHERS Stacked (more or less) according to priority.

At the end, Completed tickets must not be deleted until some documentation is at least linked to from the user page.

to do
 BrainstormingPriority-high.png
Find some tangent space normal maps pov macro or built in function.


done
 MRPriority-medium.png
Render only visible Layer.


in progress Inprogress50.jpg 40%
 LanuHumPriority-low.png
Add some procedurals.


to do
 MRPriority-low.png
Edges for toon rendering (try with a very thin slope map)


to do
 MRPriority-low.png
Add Object Depth of Field support. (Distance based is currently available)


to do
 BrainstormingPriority-low.png
Add Motion Blur (using realistic camera macro? Or new improvements since beta 39 of POV-Ray 3.7?)


to do
 BrainstormingPriority-low.png
Ambient occlusion (via proximity pattern?)


in progress Inprogress100.jpg 90%
 CR MRPriority-low.png
The texture code has some redundant parts that might be better implemented as functions.


done
 BrainstormingPriority-low.png
Render only visible/renderable objects (outliner).


in progress Inprogress25.jpg 20%
 MRPriority-experienced.png
Render Baking (using new improvements to camera since beta 39 of POV-Ray 3.7)


to do
 MRPriority-experienced.png
Add exclusion from media option per light


in progress Inprogress25.jpg 20%
 MRPriority-experienced.png
Add Blurry Reflection/Refraction Hack.


 Click For POV-Wiki!
Add importance sampling of radiosity (new since beta 39 of POV-Ray 3.7).


 Click For POV-Wiki!
-Allow some command line arguments to be passed


 Click For POV-Wiki!
More Depth of Field UI control


done
 
Allow materials or objects to be replaced by POV-Ray text files with the same name. These blender text files use the include keyword to link other inc files from the disk.