PovEdge

A simple tool to draw the edges of your mesh objects in PovRay


Home

How it works

How to use

Download

F.A.Q.

 

©Thibaut Jonckheere  

Contact :
tuabihtucl at yahoo dot fr

General questions
   
• What is PovRay ?
        PovRay is a freeware raytracer, available here : www.povray.org
It can produce stunning realistic images (see the Hall of Fame), but is also highly versatile, allowing for example cel-shading with edges. PovEdge is meant to work only with PovRay.

    • On which platform is PovEdge available ?
        Currently, PovEdge runs on Windows only. Hopefully, I will be able to do a Linux version in the future.

    • What is PoseRay ?
        PoseRay is a free converter from many 3D formats to the mesh2 PovRay format. It is available here. Is it very useful to convert the tons of  models available here and there in various formats, and then to use these models with PovEdge. But it can also improve or repair the models (see below).

Tips & tricks
    • Easy fine-tuning
        As the edges are rendered using a PovRay macro, a lot of parameters can be modified for a better control of the results. Basically, you simply need to edit the file "declarations_mymesh.inc". Things should be more or less explanatory. You can for example:

            - apply different contour widths to the different meshes. To do so, simply modify the width declared for each object before its macro call. This is very useful if you have meshes with very different sizes.

            - apply different thresholds to the different meshes, by changing the parameter EdThresh before each macro call

            - apply different colors to the different meshes. The textures for the edges are also defined before each macro call (parameter " Cyltex"). Colored edges (non black) can be classy !

            - remove some edges from the union defining the objet "Edges_mymesh". To do this, simply comment some lines in the declaration of Edges_mymesh, at the bottom of "declarations_mymesh.inc". This is useful to remove for example some unwanted creases edges for certain meshes.


 
    • Useful things to do using PoseRay
          Apart from converting 3D models to the mesh2 format, PoseRay can many other useful things for the PovEdge user. You can:
            
            - subdivide the models, to get a finer mesh. You will get smoother edges (and shadows) with a finer mesh.

            - weld the models (this is done in the "Groups" tab, check "Weld vertices" and then click "update"). This can remove some unwanted edges when the model should be connected but is in fact composed of several pieces.

            - correct the normals by re-calculating them (with "Calculate normals", right above weld). Sometimes, models have some errors in the normals, without visible effect on a standard render of the object, but which gives wrong edges. Re-calculating the normals solves this. 

        Note that PoseRay can also import the mesh2 format. Although this sounds stupid at first (why should I import a PovRay model in a converter to the PovRay format?), it allows you to subdivide PovRay models, or to correct them ! It is also useful if PovEdge has problems at parsing the mesh file (this can happen sometimes when the syntax is not 100% standard): simply import it in PoseRay (which is more robust at parsing non standard syntax), and export it. PovEdge can always parse the models exported from PoseRay.


Troubleshooting

        • How do I get a cel-shading like texture ?
            There is room for lots of experimentation here. To get a "flat" texture, use a low brilliance (smaller than 1 which is the default), or even 0. Put a single light-source, and put a decent amount of ambient in the texture.

        • When I use toon shading textures with low brilliance, I get strange shadows (the borders of the shadows are jagged)
           
This is an annoying problem which is specific to the combination of mesh and low or zero brilliance. It can be fixed by subdividing the mesh (for example with PoseRay, see Tips&Tricks), to get a smoother border between shadowed and non-shadowed parts.

        • I can't get the crease edges right: with a low EdThresh I get none, but if I increase EdThresh I immediately get artifacts.   
           
Crease edges can be difficult to get right sometimes, specially with low-poly meshes (because in a low-poly mesh, the angle between two neighbourhing face is quite large even for smooth parts of the mesh, where crease edges should not be present). A solution can be simply to subdivide the mesh (for example with PoseRay, see Tips&Tricks).