OpenSceneGraph Forum Forum Index OpenSceneGraph Forum
Official forum which mirrors the existent OSG mailing lists. Messages posted here are forwarded to the mailing list and vice versa.
 
   FAQFAQ    SearchSearch    MemberlistMemberlist    RulesRules    UsergroupsUsergroups    RegisterRegister 
 Mail2Forum SettingsMail2Forum Settings  ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
   AlbumAlbum  OpenSceneGraph IRC ChatOpenSceneGraph IRC Chat   SmartFeedSmartFeed 

Regarding Culling in osg


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
Rambabu
Appreciator


Joined: 10 Nov 2016
Posts: 101

PostPosted: Sat Apr 22, 2017 7:21 am    Post subject:
Regarding Culling in osg
Reply with quote

Hi,Can anyone tell me is there any example code (i.e .cpp file )for Backfaceculling,face culling and frustum culling in osg.

Any Help is appreciated.

...

Thank you!

Cheers,
Rambabu
Back to top
View user's profile Send private message
mp3butcher (Julien Valentin)
Appreciator


Joined: 17 Feb 2010
Posts: 423
Location: France

PostPosted: Sat Apr 22, 2017 4:06 pm    Post subject:
Re: Regarding Culling in osg
Reply with quote

Hi,

Forum is plenty of information about osg culling
http://forum.openscenegraph.org/viewtopic.php?t=15959
http://forum.openscenegraph.org/viewtopic.php?t=16095

More generally, you can search the forum by yourself for the term "CullCallback" or "CullVisitor" or "CullFace"
And come back when your question is more precise

Cheers

Rambabu wrote:
Hi,Can anyone tell me is there any example code (i.e .cpp file )for Backfaceculling,face culling and frustum culling in osg.

Any Help is appreciated.

...

Thank you!

Cheers,
Rambabu
Back to top
View user's profile Send private message Visit poster's website
Rambabu
Appreciator


Joined: 10 Nov 2016
Posts: 101

PostPosted: Mon Apr 24, 2017 5:57 am    Post subject:
Reply with quote

Hi,Julien Thanks for the reply and Iam having another doubt in CullCallback.cpp which iam mentioning below

He is reading from command line what is the exact meaning of --test,test1,test2...... etc means and what i have to give in the command line to execute this code?
if (arguments.read("--test"))
{
osg::ref_ptr<osg::Group> root = new osg::Group();
rootnode = root;

osg::Node *test1 = new osg::Node();
test1->setUpdateCallback(new TestNodeUpdateCallback("test1"));
root->addChild(test1);

osg::Drawable *test2 = new osg::Drawable();
test2->osg::Node::setUpdateCallback(new TestNodeUpdateCallback("test2"));
root->addChild(test2);

osg::Drawable *test3 = new osg::Drawable();
test3->setUpdateCallback(new TestDrawableUpdateCallback("test3"));
root->addChild(test3);

osg::Geode *test4 = new osg::Geode();
osg::Drawable *drawable1 = new osg::Drawable();
drawable1->osg::Node::setUpdateCallback(new TestNodeUpdateCallback("test4"));
test4->addDrawable(drawable1);
root->addChild(test4);

osg::Geode *test5 = new osg::Geode();
osg::Drawable *drawable2 = new osg::Drawable();
drawable2->setUpdateCallback(new TestDrawableUpdateCallback("test5"));
test5->addDrawable(drawable2);
root->addChild(test5);

osg::Geode *test6 = new osg::Geode();
osg::Drawable *drawable3 = new osg::Drawable();
drawable3->setUpdateCallback(new TestDrawableUpdateCallback("test6"));
test6->addChild(drawable3);
root->addChild(test6);

osg::Geode *test7 = new osg::Geode();
osg::Drawable *drawable4 = new osg::Drawable();
drawable4->osg::Node::setUpdateCallback(new TestNodeUpdateCallback("test7"));
test7->addChild(drawable4);
root->addChild(test7);

printf("Numchildren with updates %u\n", rootnode->getNumChildrenRequiringUpdateTraversal());

Any Help is appreciated.


...

Thank you!

Cheers,
Rambabu
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Similar Topics
Topic Author Forum Replies Posted
No new posts Camera serializer and culling mp3butcher General 1 Sat Apr 21, 2018 12:16 pm View latest post
No new posts AutoTransform, ROTATE_TO_SCREEN and s... hartwigw General 7 Mon Mar 26, 2018 9:28 pm View latest post
No new posts Prevention of near plane culling whil... hartwigw General 3 Sat Mar 10, 2018 7:57 am View latest post
No new posts inactive Culling and update Near/Far Mathieu Submission 1 Mon Dec 04, 2017 9:46 am View latest post
No new posts Do not cull inactive culling drawables Mathieu Submission 0 Fri Dec 01, 2017 3:50 pm View latest post


Board Security Anti Bot Question MOD - phpBB MOD against Spam Bots
Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP