Re: [info-performer] Fw: Flt loader with shaders.

Date view Thread view Subject view Author view

From: Alexandre Naaman (naaman++at++gmail.com)
Date: 09/08/2005 15:30:14


Hi Jason, Vincent,

  You're correct, we haven't updated the loader since version 15.7.
At first glance it looks like v15.8 is mostly a fix release (15.7 was
buggy, if you can believe that a spec can be buggy) and version 16.0
has added support for shaders (Cg, CgFX and GLSL).

  If anyone here has flt files that require these mods please send
them my way and I'll file a bug and we'll see what can be done for
future releases of Performer.

A+,

Alex.

On Sep 7, 2005, at 7:13 AM, Jason Daly wrote:

> Vincent Pasqualato wrote:
>
>
>> Hi !
>>
>> Trying to combine a shader program written in GLSL with a
>> Performer scene
>> graph, we discovered that rendering an flt object with faces which
>> are flats
>> (no gouraud/interpolation, no vertex normals) gives us strange
>> results :
>> The flt loader seems to try some computation of vertex normals,
>> because
>> there is a variation of the normal we get from Open GL (in gl_Normal
>> parameter of the shader program) across the faces. Plus, this
>> interpolation
>> is buggy, resulting in very strange patterns of normals on the
>> object.
>> If we transform our object in gouraud, and pre-compute the vertex
>> normals,
>> the rendering is OK, except we don't get the flat faces we would
>> want.
>> Does anyone have a suggestion about this behaviour ? Is there an
>> option to
>> deactivate this normal computation ? Or is it correct, assuming
>> the classic
>> OpenGL pipeline doesn't take into account vertex normals when
>> rendering flat
>> faces ?
>>
>>
>
> There is supposed to be:
>
> pfdConverterMode_flt(PFFLT_COMPUTENORMALS, PF_OFF);
>
> but last time I tried, it didn't work.
>
>
>> Also, another problem with flt loader and Shaders is the fact that
>> the
>> loader seems to make some pre-computation on vertex colors and face
>> materials : vertex colors seems to be multplicated by the diffuse
>> color of
>> the faces, and ambient and diffuse color of the face seem also to be
>> affected by the color of the vertex. Although this doesn't affect
>> classic
>> OpenGL rendering, it is incompatible with our shader, which make a
>> different
>> use of this colors and need them untransformed.
>>
>>
>
> I think there's supposed to be a mode for this as well, but I can't
> pick it out just from the pfflt.h file (and it probably wouldn't
> work anyway). Performer used to ship with the pfdConverterMode_flt
> man page, but no longer. The loader is also several years out of
> date (I think it's only good for versions 15.7 and earlier). I
> know MPI stopped supporting their Performer loader a while ago, and
> SGI hasn't kept up with OpenFlight versions since 15.7.
>
> --
>
> --"J"
>
> "I'm a castaway stranded in a desolate land,
> I can see the footprints in the virtual sand."
> --Neil Peart
>
> ----------------------------------------------------------------------
> -
> List Archives, Info, FAQ: http://www.sgi.com/software/performer/
> Open Development Project: http://oss.sgi.com/projects/performer/
> Submissions: info-performer++at++sgi.com
> Admin. requests: info-performer-request++at++sgi.com
> ----------------------------------------------------------------------
> -
>


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Thu Sep 08 2005 - 15:31:13 PDT