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 

asymmetrical viewing volume


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
Gianluca Natale
Guest





PostPosted: Tue Oct 28, 2008 2:23 pm    Post subject:
asymmetrical viewing volume
Reply with quote

Hi all.
I need to set a projection matrix for an asymmetrical
viewing volume.
Settings for the scene view associated with the camera
are:
osg::CullSettings::COMPUTE_NEAR_FAR_USING_BOUNDING_VOLUMES.


I tried with camera.SetProjectionMatrixAsFrustum(…),
but it resets left and right clipping planes to a symmetrical frustum,
when I call camera.frame(…).

Is it because the near and far clipping planes need to be updated
during redraw?

Is there a way to prevent this behavior, having only near and far
clipping planes updated?

Thanks
Gianluca

------------------
Post generated by Mail2Forum
Back to top
Robert Osfield
Guest





PostPosted: Tue Oct 28, 2008 3:36 pm    Post subject:
asymmetrical viewing volume
Reply with quote

Hi Gianluca,

The default compute of near/far is something that you can disable via:

viewer.getCamera()->setComputeNearFarMode(osg::CullSettings::DO_NOT_COMPUTE_NEAR_FAR);

But even if you don't call this a let the near far be recomputed it
won't affect the asymmetry of the projection matrix. For instance the
osgwindow example runs with an asymmetric frustum and runs fine. Also
when you enable stereo it'll be use asymmetric frustum.

Robert.

On Tue, Oct 28, 2008 at 2:22 PM, Gianluca Natale
<> wrote:
Quote:
Hi all.
I need to set a projection matrix for an asymmetrical
viewing volume.

Settings for the scene view associated with the camera
are:

osg::CullSettings::COMPUTE_NEAR_FAR_USING_BOUNDING_VOLUMES.

I tried with camera.SetProjectionMatrixAsFrustum(?),
but it resets left and right clipping planes to a symmetrical frustum,
when I call camera.frame(?).



Is it because the near and far clipping planes need to be updated
during redraw?



Is there a way to prevent this behavior, having only near and far
clipping planes updated?



Thanks

Gianluca








------------------
Post generated by Mail2Forum
Back to top
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 答复: osg-users Digest, Vol 105, Is... 韩志平 General 1 Thu Feb 09, 2017 3:03 am View latest post
No new posts Viewing Image in osgviewer using c++ ... umadevi2193 General 1 Sat Sep 24, 2016 10:10 am View latest post
No new posts Viewing Stacked Semi-Transparent Geodes ehensens General 4 Wed Feb 03, 2016 8:48 pm View latest post
No new posts Volume image crash on the latest vers... Clement General 23 Tue Aug 04, 2015 6:23 am 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