}
}
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
Hi Sebastian,Perhaps your GPU can use doubles ? Many of them can these days. You may also try to refactor the code to use pairs of floats (as base and offset) which in theory may be almost as precise as double. It may be however very tricky for such non-linear math as geographic projections...
Cheers,Wojtek
}
}
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________ osg-users mailing list osg-...@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Hi Sebastian,
Just an extra thought that came to me. Terrain LOD paging may cause the elevation jumps too. When LODs change meshes get denser or less dense - new vertices show up or excess vertices hide and that may also bring lot of surprises.
Cheers,Wojtek
}
}
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________ osg-users mailing list osg-...@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Hi Sebastion,
when you deal with geocentric data, the precision is an issue even if it is not on the GPU. The way how TerraVista (you have heard of it, right) was solving this was by introducing a matrix of doubles for the origin or the center of the tile and all the math was then with floats locally to the tile, in other words, all terrain tiles resides in their local floats coordinate system with doubles matrix on top. It is still possible to work with floats this way - that is how I did the geocentric whole earth terrapage - well, Robert pointed me to this trick. My two cents.
Hi,
I have a osgDEM produced geocentric database.
I looked into the geometryTechnique implementation to see if I somehow can access the height of the vertices above the ellipsoid in the vertex shader.
Unfortunately I don't have any idea how to calculate this from the give matrices. Is this information somehow available at all?
My plan is to overwrite some of the functionality in the geometryTechnique to pass the appropriate matrices to the shader.
Anyone having an idea?
_______________________________________________
osg-users mailing list
Sabastian,
osgEarth does more or less what Robert describes. We encode each vert's height value (and unit vector) in a vertex attribute.
Sabastian,
osgEarth does more or less what Robert describes. We encode each vert's height value (and unit vector) in a vertex attribute.
On Dec 6, 2013 5:43 AM, "Robert Osfield" <robert....@gmail.com> wrote:
Hi Sebastian,
Personally I'd subclass from osgTerrain::GeometryTechnique and pass a FloatArray as a vertex attrib array or tex coord array and store the heights there.
Robert.
On 4 December 2013 13:23, Sebastian Messerschmidt <sebastian.m...@gmx.de> wrote:
Hi,
I have a osgDEM produced geocentric database.
I looked into the geometryTechnique implementation to see if I somehow can access the height of the vertices above the ellipsoid in the vertex shader.
Unfortunately I don't have any idea how to calculate this from the give matrices. Is this information somehow available at all?
My plan is to overwrite some of the functionality in the geometryTechnique to pass the appropriate matrices to the shader.
Anyone having an idea?
_______________________________________________
osg-users mailing list
_______________________________________________
osg-users mailing list
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Hi Sebastian,
Personally I'd subclass from osgTerrain::GeometryTechnique and pass a FloatArray as a vertex attrib array or tex coord array and store the heights there.
Robert.
On 4 December 2013 13:23, Sebastian Messerschmidt <sebastian.m...@gmx.de> wrote:
Hi,
I have a osgDEM produced geocentric database.
I looked into the geometryTechnique implementation to see if I somehow can access the height of the vertices above the ellipsoid in the vertex shader.
Unfortunately I don't have any idea how to calculate this from the give matrices. Is this information somehow available at all?
My plan is to overwrite some of the functionality in the geometryTechnique to pass the appropriate matrices to the shader.
Anyone having an idea?
_______________________________________________
osg-users mailing list
The heights are relative to the ellipsoid, yes. I can send you a code link when I get back (in on the road atm).