Thansk for pointing me to these topics.
So, I found the solution : (be carefull, these function use WORLD coordinates,
not local coordinates)
worldToScreen :
Code:
osg::Vec2d worldToScreen(const osg::Vec3d worldPosition, const osg::Camera*
pCamera)
{
osg::Vec2d screenPosition;
if
=1786highlight=
-Shayne
-Original Message-
From: osg-users-boun...@lists.openscenegraph.org
[mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of
Aurelien Albert
Sent: Sunday, September 25, 2011 6:26 AM
To: osg-users@lists.openscenegraph.org
Subject: [osg-users] Draw a line from world
Hi,
I've made an Segment object which draw a segement from a point (x, y, z) to
another (x, y, z) and working well.
Now, I want to draw a Connector line from a point in space (x, y, z) to a
point on screen (x, y).
How can I transform my (x, y) screen point to find a equivalent (x, y, z) world
3 matches
Mail list logo