[osg-users] re Paul Martz in osgEphemeris

2009-08-28 Thread osghxl
hi,Paul Martz
Your reply is blank,I hope you can give me some advice.
Thanks
regards,
houxl
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Jean-Sebastien Guay,kim in osgOCean application

2009-08-25 Thread osghxl
hi,Jean-Sebastien Guay,kim and others:
 
sorry,we are in different time zones,it is difficult for me to keep online in 
touch with you.
 As you said ,i disable full screen and glare effect,and load spaceship.osg in 
osgOcean application.The transparent flame trail of spaceship is rendered 
correctly,but the color of transparent flame trail is not colorful ,just grey 
or white(highlight).I adjust the scene light source parameters,but have no 
effect.Do you solve the problem in your lab ? Can you post me codes explaining 
the solutions?
 
regards,
houxl.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] re :transparent objects render in osgOcean

2009-08-25 Thread osghxl
hi,kim ,Jean-Sebastien Guay and others:
I have registered an account in forem,but the messages i sent is awaiting 
approval.So i post my reply by mailing list.
in osgocean example ,i disable glare and dof false in ocean scene 
initialization.
...
_oceanScene-enableUnderwaterDOF(false);
_oceanScene-enableGlare(false);
...
then,i print screen and get some images which are in email attachments.
(1)render correctly no ocean.JPG
the image is rendered in osgviererMFC.the flame trail is colorful.
(2)(application init) disable glare and dof(underwater).JPG
in osgocean example initialization:
_oceanScene-enableUnderwaterDOF(false);
_oceanScene-enableGlare(false);
after initialization,i don't press usful key to change effects.
(3)(run-time )disable glare and dof(underwater).JPG
at run-time,i press key to toggle glare and dof(underwater) false.

From the three images you maybe know what happen in spaceship flame trail.In 
fact ,i want to get the reason why the flame trail turns grey or white when i 
toggle glare and dof(underwater) false at run time.If you have solutions 
,please send me codes explaining it.

Thank you!

Cheers,
houxl

 



attachment: render correctly no ocean.JPGattachment: (application init) disable glare	and dof(underwater).JPGattachment: (run-time )disable glare and	dof(underwater).JPG___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] osgOcean application

2009-08-23 Thread osghxl
Hi ,all:
In the ocean example attached osgOcean,i loaded a 3d model which is named 
spaceship.osg from osg offical data, but i did not find the transparent 
colorful flame trail of spaceship,which exist in fact if spaceship was rendered 
correctly . why?
the code as follows:
//==
...
 osg::ref_ptrosg::Node loadedModel = osgDB::readNodeFiles(arguments);
// any option left unread are converted into errors to write out later.
arguments.reportRemainingOptionsAsUnrecognized();
// report any errors if they have occurred when parsing the program 
arguments.
if (arguments.errors())
{
arguments.writeErrorMessages(std::cout);
return 1;
}
osgViewer::Viewer viewer;
viewer.setUpViewInWindow( 150,150,1024,768, 0 );
viewer.addEventHandler( new osgViewer::StatsHandler );
osg::ref_ptrTextHUD hud = new TextHUD;
osg::ref_ptrSceneModel scene = new SceneModel(windDirection, windSpeed, 
depth, scale, isChoppy, choppyFactor, crestFoamHeight);
viewer.addEventHandler(scene-getOceanSceneEventHandler());
viewer.addEventHandler(scene-getOceanSurface()-getEventHandler());
viewer.addEventHandler( new SceneEventHandler(scene.get(), hud.get(), 
viewer ) );
viewer.addEventHandler( new osgViewer::HelpHandler );
osg::Group* root = new osg::Group;
root-addChild( scene-getScene() );
root-addChild( hud-getHudCamera() );
if (loadedModel.valid())
{
loadedModel-setNodeMask( scene-getOceanScene()-getNormalSceneMask() 
| 
scene-getOceanScene()-getReflectedSceneMask() 
| 
scene-getOceanScene()-getRefractedSceneMask() 
);
scene-getOceanScene()-addChild(loadedModel.get());
}
   // load spaceship ,added by me
 osg::ref_ptrosg::PositionAttitudeTransform pat = new 
osg::PositionAttitudeTransform();
 //osg::Vec3(10.0f,0.0f,0.0f)
 pat-setPosition(osg::Vec3(0.0f,0.0f,20.0f));
   osg::ref_ptrosg::Node spaceship= osgDB::readNodeFiles(spaceship.osg);
if (spaceship.valid())
{
spaceship-setNodeMask( scene-getOceanScene()-getNormalSceneMask() | 
scene-getOceanScene()-getReflectedSceneMask() 
| 
scene-getOceanScene()-getRefractedSceneMask() 
);
pat-addChild(spaceship.get());
scene-getOceanScene()-addChild(pat.get());
}
viewer.setSceneData( root );
viewer.realize();
while(!viewer.done())
{
viewer.frame();
}
return 0;___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] re :Kim and Jean-Sebastien Guay in osgOcean application(render transparent objects)

2009-08-23 Thread osghxl
Hi,Kim and Jean-Sebastien Guay 
thank your good advice!
I am very interested in ocean water rendering, osgOcean is a very good module 
of osg.But i think that some functionality is added in osgOcean.
as follows:
1)as kim said,add another transparency  processing pass,and make osgocean 
render transparent objects well.
I hope that kim will add transparency  processing functionality soon. If 
added,please send message to me.
2)according to longitude, latitude,date and time,simulate skydome,skylight and 
daylight,and render ocean water at any time(for example sunrise,sunset water )
3)avoid tile repeat of ocean scene (for example ,two bands samples for ocean 
spectrum )
I want to join in development of osgOcean ,and hope kim and Jean-Sebastien Guay 
to help me solve some problems.
regards,
houxl(osghxl).___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org