POV-Ray : Newsgroups : povray.off-topic : The most common 3D mesh file format? Server Time
6 Sep 2024 17:21:09 EDT (-0400)
  The most common 3D mesh file format? (Message 1 to 10 of 40)  
Goto Latest 10 Messages Next 10 Messages >>>
From: Severi Salminen
Subject: The most common 3D mesh file format?
Date: 26 Jan 2009 08:21:27
Message: <497db8d7$1@news.povray.org>
As you maybe remember, I'm programming ssRay, a Monte Carlo path tracer.
Next I'd like to add mesh support for more interesting shapes. What
would be the most common mesh file format? Or at least common enough AND
simple?

Regards,
Severi

ssRay:

http://www.saunalahti.fi/~sevesalm/ssRay/ssRay.php


Post a reply to this message

From: Kyle
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 08:34:47
Message: <497dbbf7$1@news.povray.org>
I'd suggest the Wavefront OBJ file format...

http://en.wikipedia.org/wiki/Obj


Post a reply to this message

From: somebody
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 08:59:08
Message: <497dc1ac$1@news.povray.org>
"Kyle" <no### [at] spamok> wrote in message news:497dbbf7$1@news.povray.org...

> I'd suggest the Wavefront OBJ file format...
>
> http://en.wikipedia.org/wiki/Obj

OBJ is a decent format, but I'd say 3DS is still unfortunately the most
common one.


Post a reply to this message

From: triple r
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 09:20:00
Message: <web.497dc5c7c930bdbfef2b9ba40@news.povray.org>
Kyle <no### [at] spamok> wrote:
> I'd suggest the Wavefront OBJ file format...
>
> http://en.wikipedia.org/wiki/Obj

OBJ is extremely simple, too.  Just ASCII text, so I was able to
reverse-engineer it and make a shell script to convert it to mesh2 format.  3DS
appears to be binary formatted which, while not difficult to work with, is that
much more complex for debugging.

 - Ricky


Post a reply to this message

From: Mike Hough
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 16:55:07
Message: <497e313b$1@news.povray.org>
I found that aspect of OBJ extremely useful in testing my exporter for Hash 
AM. I could just open the file and see if everything was being written 
correctly.

Another advantage of OBJ is that it support quads. I think 3DS only supports 
triangles?

"triple_r" <nomail@nomail> wrote in message 
news:web.497dc5c7c930bdbfef2b9ba40@news.povray.org...
> Kyle <no### [at] spamok> wrote:
>> I'd suggest the Wavefront OBJ file format...
>>
>> http://en.wikipedia.org/wiki/Obj
>
> OBJ is extremely simple, too.  Just ASCII text, so I was able to
> reverse-engineer it and make a shell script to convert it to mesh2 format. 
> 3DS
> appears to be binary formatted which, while not difficult to work with, is 
> that
> much more complex for debugging.
>
> - Ricky
>


Post a reply to this message

From: Severi Salminen
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 17:15:48
Message: <497e3614$1@news.povray.org>
Kyle wrote:
> I'd suggest the Wavefront OBJ file format...
> 
> http://en.wikipedia.org/wiki/Obj

Thanks. OBJ seems fine. Any idea where I could find very simple .obj
files which contain (say) less than 100 triangles?

ssRay still lacks kd-trees so I don't want to wait millions of years
rendering that cool dragon model...


Post a reply to this message

From: andrel
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 17:18:31
Message: <497E3721.20602@hotmail.com>
On 26-Jan-09 23:15, Severi Salminen wrote:
> Kyle wrote:
>> I'd suggest the Wavefront OBJ file format...
>>
>> http://en.wikipedia.org/wiki/Obj
> 
> Thanks. OBJ seems fine. Any idea where I could find very simple .obj
> files which contain (say) less than 100 triangles?
> 
> ssRay still lacks kd-trees so I don't want to wait millions of years
> rendering that cool dragon model...
use blender, wings3d or something like that and export a few basic 
shapes as obj


Post a reply to this message

From: Warp
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 18:46:25
Message: <497e4b51@news.povray.org>
Mike Hough <nos### [at] nospamcom> wrote:
> Another advantage of OBJ is that it support quads. I think 3DS only supports 
> triangles?

  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.

-- 
                                                          - Warp


Post a reply to this message

From: clipka
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 19:15:00
Message: <web.497e5100c930bdbf122a8da90@news.povray.org>
Warp <war### [at] tagpovrayorg> 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

From: Mike Hough
Subject: Re: The most common 3D mesh file format?
Date: 26 Jan 2009 19:26:38
Message: <497e54be$1@news.povray.org>
As clipka said, they usually get triangulated at render time. I have only 
written exporters, not renderers, so I don't know how it is actually 
handeled by the program after they are imported. However quads imported into 
all programs I have tried using OBJ format do not appear to suffer any 
texturing problems. This is an advantage in blender because subdivision 
surfaces work much better on quads than on triangles.

"Warp" <war### [at] tagpovrayorg> wrote in message 
news:497e4b51@news.povray.org...
> Mike Hough <nos### [at] nospamcom> wrote:
>> Another advantage of OBJ is that it support quads. I think 3DS only 
>> supports
>> triangles?
>
>  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.
>
> -- 
>                                                          - Warp


Post a reply to this message

Goto Latest 10 Messages Next 10 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.