Re: [osg-users] VertexAttribArrayList serialization

2014-04-16 Thread Pjotr Svetachov
I think the problem with the generated file is that the vertex attributes begin 
at 6 and the attributes 0 to 5 are null pointers and are not written. Then when 
reading the reader expects 8 arrays but there are only 2 written so it messes 
up reading them. I also noticed that, unlike in the osg format there is no way 
to tell to what attribute number to bind an array.

Cheers,
Pjotr

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=58952#58952





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-16 Thread Sebastian Messerschmidt

Hi Pjotr,

I think the problem with the generated file is that the vertex attributes begin 
at 6 and the attributes 0 to 5 are null pointers and are not written. Then when 
reading the reader expects 8 arrays but there are only 2 written so it messes 
up reading them. I also noticed that, unlike in the osg format there is no way 
to tell to what attribute number to bind an array.
Apart from the binding, it was working before. There seem to be changes 
in the serialization.
Unfortunately one cannot use arbitrary numbers here, since drivers do a 
default mapping between default vertex attributes and the attribute 
slots in the shader program.


cheers
Sebastian



Cheers,
Pjotr

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=58952#58952





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-16 Thread Pjotr Svetachov
I'm not familiar with the new osg(t/b) writers (we still use osg and ive here 
but are also considering a switch) but looking at the commit log there was a 
change in the revision 14099 that added a new way to serialize arrays to 
support the lua plugin which seems to change the layout also.

Cheers,
Pjotr

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=58957#58957





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-16 Thread Robert Osfield
HI Sebastian,

On 15 April 2014 10:59, Sebastian Messerschmidt
sebastian.messerschm...@gmx.de wrote:
 I'm a bit lost with the issue. Isn't the osgb-format supposed to be stable?

The format isn't stable, as new features get added or changed in the
OSG.   However, it is versioned and should in theory allow older files
to be read with new versions of the OSG.

 Can you at least point me to the revision where this might have changed?
 Summarized: It seems files written by the trunk-revision 14033 cannot be
 read by older versions (osg111, 3.3.1). Also files containing vertex
 attribute arrays cannot be read by the revision it was written with.

The format is forwards compatible rather than backwards compatible.
While I do try and avoid changes to existing parts of format sometimes
it's not possible to implement new features or refactor old features
without implementing changes that break forwards compatibility.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-16 Thread Sebastian Messerschmidt

Hi Robert

HI Sebastian,

On 15 April 2014 10:59, Sebastian Messerschmidt
sebastian.messerschm...@gmx.de wrote:

I'm a bit lost with the issue. Isn't the osgb-format supposed to be stable?

The format isn't stable, as new features get added or changed in the
OSG.   However, it is versioned and should in theory allow older files
to be read with new versions of the OSG.


Can you at least point me to the revision where this might have changed?
Summarized: It seems files written by the trunk-revision 14033 cannot be
read by older versions (osg111, 3.3.1). Also files containing vertex
attribute arrays cannot be read by the revision it was written with.

The format is forwards compatible rather than backwards compatible.
While I do try and avoid changes to existing parts of format sometimes
it's not possible to implement new features or refactor old features
without implementing changes that break forwards compatibility.

Okay, I'll keep that in mind.
But in the specific case, the serializer cannot read what it wrote. So 
this might be worth investigating.


cheers
Sebastian


Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-15 Thread Sebastian Messerschmidt

Hi Robert,

I'm a bit lost with the issue. Isn't the osgb-format supposed to be stable?
Can you at least point me to the revision where this might have changed?
Summarized: It seems files written by the trunk-revision 14033 cannot be 
read by older versions (osg111, 3.3.1). Also files containing vertex 
attribute arrays cannot be read by the revision it was written with.


cheers
Sebastian
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] VertexAttribArrayList serialization

2014-04-14 Thread Sebastian Messerschmidt

Hi,

I've just found some curious bug in the osg(t/b) serializers.
Currently I'm using a more or less up2date trunk.
When I add vertex-attributes for tangent space to a node and write out 
the file, it is no longer readable by osg. I'll try to provide a  
minimal example demonstrating the issue.
Have there been any changes recently which could explain this? Checking 
the log I didn't catch anything suspicious.


cheers
Sebastian

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] VertexAttribArrayList serialization

2014-04-14 Thread Sebastian Messerschmidt
Also it seems that older version of osg (osg111) cannot read these files 
even without vertex attributes.

Has there been a breaking change in the serialization format?

cheers
Sebastian

Hi,

I've just found some curious bug in the osg(t/b) serializers.
Currently I'm using a more or less up2date trunk.
When I add vertex-attributes for tangent space to a node and write out 
the file, it is no longer readable by osg. I'll try to provide a  
minimal example demonstrating the issue.
Have there been any changes recently which could explain this? 
Checking the log I didn't catch anything suspicious.


cheers
Sebastian

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org