Ok I think it is working now with
eometry->getVertexAttribArray(s_attributeIndex)->dirty();
Thank you :)
--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=50413#50413
___
osg-users mailing list
osg-us
Btw I am using osg 2.8.3-4, not sure if it could make any difference
--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=50412#50412
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lis
Hi Sebastian,
I set the vertex attribute array this way:
Code:
geometry->setVertexAttribArray(s_attributeIndex, m_vertexAttributes.get());
geometry->setVertexAttribBinding(s_attributeIndex,
osg::Geometry::BIND_PER_VERTEX);
geometry->setVertexAttribNormalize(s_attributeIndex, GL_FALSE);
and
Hi Janna,
can you provide the bits of your code where you setup the attributes in
the c++ code and the GLSL part where you access it?
I've been using this feature for tangent-space attributes like forever
and it simply works.
The only thing to keep in mind is the slot numbers and names you are
Hi,
I've tried to use gl_MultiTexCoord1 and do geometry->setTexCoordArray(1,
secondTexCoords);
instead of custom vertex attributes to pass my data and it seems to be working.
Does anyone know if there is some kind of problem with using custom vertex
attributes ( using methods like setVerte
This is being done and as I mention it works fine unless I try to use vertex
buffer object.
so lets say code like this works:
Code:
geometry->setVertexAttribArray(s_attributeIndex, m_vertexAttributes.get());
geometry->setVertexAttribBinding(s_attributeIndex,
osg::Geometry::BIND_PER_VERTEX);
Hello Janna,
If you use a shader program you'll have to bind the attributes to the
program:
const std::string name="v_tangent"
program->addBindAttribLocation(name, index);
Then in the vertex shader you can access the attribute via:
attribute vec3 v_tangent;
hth
Sebastian
Hi,
I am working o
Hi,
I am working on optimizing existing code for height field. I've enabled VBO for
height field geometry which seems to make draw time faster however it seems can
not retrieve vertex attribute data in the vertex shader anymore.
Is there a special way of using VBO with geometry which has additi
8 matches
Mail list logo