Re: [osg-users] pfDCS replacement

2015-08-28 Thread Tony Vasile
Is there any reason it gets converted to a MatrixTransform object rather than a 
PositionAttitudeTransform object?

Tony V

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





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


Re: [osg-users] pfDCS replacement

2015-08-28 Thread Robert Osfield
Hi Tony,

On 28 August 2015 at 07:59, Tony Vasile ming...@gmail.com wrote:

 Is there any reason it gets converted to a MatrixTransform object rather
 than a PositionAttitudeTransform object?


pfSCS and pfDCS both map  most accurately to an osg::MatrixTransform with
the nodes DataVariance set to STATIC and DYNAMIC respectively.

PositionAttitudeTransform provides finer control over the generation of the
matrix so can be ore convinient to use, but there really isn't any directly
equivalent in Performer.

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


Re: [osg-users] pfDCS replacement

2015-08-28 Thread David Callu
Hi Tony

Have you take a look to osg/src/osgPlugins/pfb/* source code ?
this plugin load pfb fie in osg, so I think many answers of your question
will be there.

HTH
David

2015-08-28 5:34 GMT+02:00 Tony Vasile ming...@gmail.com:

 Okay today I am wondering which class replaces pfDCS in OSG? A Google
 search shows there use to be  a class osg::DCS but this has been removed.
 To get the same functionality do I use PositionAttitudeTransform?

 Tony V

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





 ___
 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


[osg-users] Animation problem

2015-08-28 Thread Julie Green
Hi,
Can't figure out what is the problem. I'm trying to modify geometry depending 
on time. But I'm getting an exception std::__non_rtti_object at memory 
location.. or application triggers a breakpoint.

Code:

void SurfaceCalculationThread::run()
{
while (!done)
reCalculateSurface();
};

float SurfaceCalculationThread::calculateZ(float x, float y, float t)
{
float z;
z = sqrt(((x*x) / (B*B)) + ((y*y) / ((A*A)*(sin(t)*sin(t + 1);
return z;
}

void SurfaceCalculationThread::reCalculateSurface()
{
float x, y, z;
int i = 0;
float something = (sqrt(Npolygon) / 2)*1.00;
t=time-elapsedTime_n();
for (x = -something; x = something; x += 1.0f)
{
for (y = -something; y = something; y += 1.0f)
{
(*vertices2)[i].set((*vertices)[i]);
z = calculateZ(x, y, t);
(*vertices)[i].set(osg::Vec3f(x, y, z));
i++;
}
}
geometry-setVertexArray(vertices2);
geometry-setUpdateCallback(new UpdateSurfaceCallback(vertices));
}





Thank you!

Cheers,
Julie

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





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


[osg-users] [osgPlugins] Json plugin not compiling on windows using MINGW

2015-08-28 Thread Sergey Cherepanov
Hi,

File: JSON_Objects
Problem:  error: conflicting declaration 'typedef long unsigned int uint32_t'
 typedef unsigned __int32 uint32_t;

An example of solving the problem:

 #if defined(__MINGW32__) || (!defined(_MSC_VER) || _MSC_VER1600)
---
 #if (defined(__MINGW32__)  __GNUC__=4  __GNUC_MINOR__8 ) || 
 (!defined(__MINGW32__)(!defined(_MSC_VER) || _MSC_VER1600))


Thank you!

Cheers,
Sergey

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





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


Re: [osg-users] Oculus+OSG

2015-08-28 Thread Björn Blissing
Hi,

I am happy to report that support for Oculus SDK 0.7.0.0 is added and merged 
into the master branch.

The latest Oculus SDK v0.6 development has been merged back into the 0.6 branch:
https://github.com/bjornblissing/osgoculusviewer/tree/sdk-v0.6

Best regards 
Björn

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





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


Re: [osg-users] LOS materail query

2015-08-28 Thread Mike Greene
OK, 

  Got this working for some cases. For example, I used Lightwave to create a 
box with a colorbar texture placed on it so I would know for sure that the 
color returned was correct. The texture I used was a plain jpg. The problem is 
when using some other .ive , ost, or .osgt files. These have embedded textures 
of some unknown format. Do I need to somehow use set/getPixelFromat in order to 
be able to retrieve to right values for the texture color ? 

I am using this to check the color values for the picked texture:


Code:

osg::Image *myImage = myTexture-getImage(0);



if (myImage) {
osg::Vec4 textureColor = 
myImage-getColor(tc);
std::cout  textureColor =   
textureColor.x()*255  ,  textureColor.y()*255  ,  
textureColor.z()*255   std::endl;

}



Thank you!

Cheers,
Mike

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





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


[osg-users] Adding custom updater to the Viewer

2015-08-28 Thread sam
Hi All,

In my application class I'm currently inheriting the osg::Viewer and doing
my own run function. It is basically a copy paste of the osg::Viewer
function just so I can add my own custom update code for networking,
entities, etc... Is there a way in osg I can do that without having to do
this override?

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