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 

osgPPU HDR culled from certain angles?


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> osgPPU [osgPPU]
View previous topic :: View next topic  
Author Message
Skylark (Jean-Sébastien Guay)
Professional


Joined: 05 Jan 2009
Posts: 2249

PostPosted: Tue Feb 08, 2011 5:38 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hello all, hello Art :-)

I have been experimenting with osgPPU's HDR example, and it looks and
works great for my purposes, and was even easy to integrate into my own
app as a test. It's interesting how easy the code is to understand,
given what it would have been without osgPPU (i.e. using OSG and all the
render targets that the effect would have required).

I have one weird problem though. When looking around in my scene, at
some camera angles the image stops updating and seems to just alternate
between the two last rendered frames continuously. I still have control
though, and if I rotate the camera again at one point it starts updating
like normal again.

When the camera is positioned at different places, it takes different
camera orientations for this to happen. But looking up towards the sky
(+Z) always makes it happen. So it kind of looks like something is being
culled in the scene graph which is causing this. I can't figure out what
though, since I've looked through osgPPU's code and it looks to me that
all the nodes (Units, Processor, etc.) have culling disabled (using
setCullingActive(false) ).

I can't reproduce this in the osgPPU HDR example itself, of course. Sad
So I'm not looking for a precise fix, but more some hints as to what to
look for. I dumped the scene and the Processor to files, and can't see
anything wrong - I've attached the ppu file for reference, but it's
really just the one from the HDR example, minus the text PPUs.

Thanks in advance,

J-S
--
______________________________________________________
Jean-Sebastien Guay
Only registered users can see emails on this board!
Get registred or enter the forums!

http://www.cm-labs.com/
http://whitestar02.webhop.org/



------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Jolley, Thomas P
Guest





PostPosted: Wed Feb 09, 2011 5:07 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hi J-S,

It sounds like a problem with how the Z-buffer is cleared. Are you clearing the Z-buffer by setting the depth test to always, setting the depth range to 1.0, and drawing polygons? If so, some OpenGl implementations will clip the polygons that are outside the frustum. Some implementations will not clip the polygons. Just make sure the polygons are always inside the frustum.

----
Tom Jolley


Quote:
-----Original Message-----
From:
[mailto:] On Behalf
Of Jean-Sébastien Guay
Sent: Tuesday, February 08, 2011 11:38 AM
To: OpenSceneGraph Users
Subject: osgPPU HDR culled from certain angles?

Hello all, hello Art :-)


Quote:

I have one weird problem though. When looking around in my
scene, at some camera angles the image stops updating and
seems to just alternate between the two last rendered frames
continuously. I still have control though, and if I rotate
the camera again at one point it starts updating like normal again.

When the camera is positioned at different places, it takes
different camera orientations for this to happen. But looking
up towards the sky
(+Z) always makes it happen. So it kind of looks like
something is being culled in the scene graph which is causing
this. I can't figure out what though, since I've looked
through osgPPU's code and it looks to me that all the nodes
(Units, Processor, etc.) have culling disabled (using
setCullingActive(false) ).

I can't reproduce this in the osgPPU HDR example itself, of
course. Sad So I'm not looking for a precise fix, but more
some hints as to what to look for. I dumped the scene and the
Processor to files, and can't see anything wrong - I've
attached the ppu file for reference, but it's really just the
one from the HDR example, minus the text PPUs.

Thanks in advance,

J-S
--
______________________________________________________
Jean-Sebastien Guay
http://www.cm-labs.com/
http://whitestar02.webhop.org/



------------------
Post generated by Mail2Forum
Back to top
art (Art Tevs)
Site Admin


Joined: 20 Dec 2008
Posts: 414
Location: Saarbrücken, Germany

PostPosted: Tue Feb 15, 2011 10:37 am    Post subject:
Reply with quote

Hi J-S,

You are right, from the osgPPU point of view the scene graph responsible for it, shouldn't be culled at all, so this couldn't be a problem.

It sounds strange. I would assume that maybe the camera does not provide frame updates anymore, when you move your view to this certain direction.


Cheers,
Art
Back to top
View user's profile Send private message Visit poster's website
Skylark (Jean-Sébastien Guay)
Professional


Joined: 05 Jan 2009
Posts: 2249

PostPosted: Tue Feb 15, 2011 12:38 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hi Art,

Quote:
You are right, from the osgPPU point of view the scene graph responsible for it, shouldn't be culled at all, so this couldn't be a problem.

It sounds strange. I would assume that maybe the camera does not provide frame updates anymore, when you move your view to this certain direction.

I'll be trying to reproduce the problem in an osgPPU example today. I'll
let you know what results (if any) I get.

Another thing is that when I activate osgPPU, suddenly the mouse
interaction with the window (i.e. click and drag to rotate the camera
with a camera manipulator for example) becomes way too sensitive (a
small drag rotates by a very large amount). I assume this might be
because of different viewport sizes between the normal camera (which I
used before) and the last osgPPU Unit. I'll be investigating this today too.

So in general, both problems seem to be related to integrating osgPPU at
the end of an existing app's rendering. So not a problem of osgPPU
itself, but just differences between behavior before and after the
integration. I'll let you know what I find, it may be useful to document
these things for future users.

Thanks,

J-S
--
______________________________________________________
Jean-Sebastien Guay
http://www.cm-labs.com/
http://whitestar02.webhop.org/


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
hybr
Appreciator


Joined: 26 Jun 2009
Posts: 454

PostPosted: Tue Feb 15, 2011 4:06 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hi all.

I've had same issues using osgPPU, for me problem was happening only when i had turned on near\far computation on viewer's camera, i've used this mode only to test some stuff so i didnt investigated this issue further. May be this will give you some hints on problem roots.

Sergey.


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Skylark (Jean-Sébastien Guay)
Professional


Joined: 05 Jan 2009
Posts: 2249

PostPosted: Tue Feb 15, 2011 4:13 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hi Sergey,

Quote:
I've had same issues using osgPPU, for me problem was happening only when i had turned on near\far computation on viewer's camera, i've used this mode only to test some stuff so i didnt investigated this issue further. May be this will give you some hints on problem roots.

Hmmm, I saw that the osgPPU HDR example's setupCamera() method disables
near/far computation, but in our framework we turn it back on in almost
all cases. So this may be the problem. I'll look into this.

If this is the problem, I would like to avoid osgPPU forcing the main
camera's compute near/far mode off, since it is useful in many cases. It
should be possible to only turn it off when going through the cull phase
for the osgPPU quads, but then turning it back on the way it was
afterwards. Ideally, osgPPU would be as unintrusive as possible on the
app's normal operation...

Thanks for the hint,

J-S
--
______________________________________________________
Jean-Sebastien Guay
http://www.cm-labs.com/
http://whitestar02.webhop.org/


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Skylark (Jean-Sébastien Guay)
Professional


Joined: 05 Jan 2009
Posts: 2249

PostPosted: Wed Feb 16, 2011 3:09 pm    Post subject:
osgPPU HDR culled from certain angles?
Reply with quote

Hi Sergey,

Quote:
Quote:
I've had same issues using osgPPU, for me problem was happening only
when i had turned on near\far computation on viewer's camera, i've
used this mode only to test some stuff so i didnt investigated this
issue further. May be this will give you some hints on problem roots.

Hmmm, I saw that the osgPPU HDR example's setupCamera() method disables
near/far computation, but in our framework we turn it back on in almost
all cases. So this may be the problem. I'll look into this.

If this is the problem, I would like to avoid osgPPU forcing the main
camera's compute near/far mode off, since it is useful in many cases. It
should be possible to only turn it off when going through the cull phase
for the osgPPU quads, but then turning it back on the way it was
afterwards. Ideally, osgPPU would be as unintrusive as possible on the
app's normal operation...

I just tried, and this was indeed the problem.

So we need to make sure the OSGPPU quads are not culled by the near/far
computation. I will look into this. Hopefully I can come up with a
solution that is general enough to be integrated into osgPPU and will
make it work correctly with all apps regardless of the compute near/far
setting they use.

Thanks again,

J-S
--
______________________________________________________
Jean-Sebastien Guay
http://www.cm-labs.com/
http://whitestar02.webhop.org/


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> osgPPU [osgPPU] 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 Avoid "render flickering" u... Paradox General 1 Fri Jan 22, 2016 5:41 pm View latest post
No new posts Contemporary multipass non-OsgPPU glo... Chris Hanson General 1 Mon Dec 14, 2015 8:47 pm View latest post
No new posts Calculate bounds of geometry in culle... danoo General 1 Fri May 02, 2014 1:58 pm View latest post
No new posts osgPPU or osgFX:EffectCompositor for ... creature General 0 Thu Oct 10, 2013 6:47 pm View latest post
No new posts osgPPU and wireframe art osgPPU [osgPPU] 4 Fri Mar 22, 2013 2:51 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