Hi,

On Sat, 2011-06-04 at 16:44 +0200, Daniel Weber wrote:
> Hello Carsten, 
> 
> -------- Original-Nachricht --------
> > Datum: Fri, 03 Jun 2011 16:15:03 -0500
> > Von: Carsten Neumann <carsten_neum...@gmx.net>
> > An: opensg-users@lists.sourceforge.net
> > Betreff: Re: [Opensg-users] Problems processing line strips
> 
> >     Hello Daniel,
> > 
> > I haven't had a chance to look at the code yet, thanks for providing the 
> > test file though!
> > 
> > On 06/03/2011 10:43 AM, Daniel Weber wrote:
> > > I'm using OpenSG2.0 to read line strips out of a .wrl file and process
> > them afterwards. I've attached a sample file containing three line strips.
> > In principle these line segments are connected, i.e., they represent a
> > closed curve. I have some trouble with the whole process and I do not know 
> > if
> > there are bugs or I'm missing something.
> > >
> > > 1) When reading the file, GL_LINES instead of GL_LINE_STRIPS are
> > generated in the geometry core. A simple example shows the issue: At the 
> > end of
> > the following code snipplet, the type of the geometry core is GL_LINES
> > instead of GL_LINE_STRIP.
> > 
> > hmm, that seems to be a case where the VRML loader/writer has taken a 
> > shortcut and just does not attempt to create LINE_STRIPS where it makes 
> > sense.
> 
> But writing and reading the geometry results in a different visualization. 
> When rendering 
> the first node (before writing to "test.wrl") you can see a straight line, 
> while the one 
> after the read results in a line stipple. 
>
> 
> > 
> > > I fixed that in my application by traversing the generated scene graph
> > and replacing all GL_LINES with GL_LINE_STRIP.
> > 
> > that gives the expected visual result, but is a bit wasteful as you will 
> > have line segments of length 0 in the strip.

that is at least a bug in the vrml loader, for an indexed line set it
should generate line strips, not lines. I'll fix that. The writer seems
ok, but I'll check that one.

kind regards
   gerrit



------------------------------------------------------------------------------
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
_______________________________________________
Opensg-users mailing list
Opensg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to