|
![](/i/fill.gif) |
Warp <war### [at] tag povray org> wrote:
> Rendering a (non-rectangular) textured quad is not an unambiguous process.
> How do you do that? Dividing it into two triangles will get you a texturing
> artifact.
Should be not too difficult: Just triangulate the nasty things.
As long as we're "only" talking about quads and not generic N-gons that should
not be a big deal. Find the shortest diagonal and cut it in two.
For users wanting more control over the results, advise them to triangulate
their models in a proper mesh editor.
At least it's one of those things I wouldn't bother too much about in the
beginning if I'd write such a program. For starters, a warning to the user and
a totally braindead automatic tesselation (or even total refusal to import the
file) should be an acceptable enough way to deal with the problem. It can
always be fleshed out in the future with more sophisticated algorithms.
It wouldn't be the first program to place certain restrictions on the data in
the .obj file to be imported. (How much software do you know, for example, that
accepts bezier patches in .obj files? Or was it nurbs? Even the number of
programs that can do arbitrary N-gons is probably quite limited; e.g. Poser
only accepts triangles and quads.)
BTW, there's another issue with 3DS files: As far as I see, there seems to be a
"hard deck" at 32k triangles. At least that's where various programs start
messing up their 3DS export (not only seen in freeware stuff like Wings 3D, but
also in commercial software like Poser 7).
Never seen such problems with .obj files.
Post a reply to this message
|
![](/i/fill.gif) |