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 

Large number of occluder nodes


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
d_a_heitbrink (David Heitbrink)
User


Joined: 23 Sep 2013
Posts: 52

PostPosted: Wed May 30, 2018 10:10 pm    Post subject:
Large number of occluder nodes
Reply with quote

I have a scene with a large number of occluder nodes. Its a large city scene, and most of the nodes are relatively small, like 10-50 meters wide, like 10-30 meters tall, in a database that is maybe 20 km x 20 km. I have 1000's of these. They are basically extracted semi-automatically. Most of them are simple just a 4 points.

My cull time is getting up to the 40ms range. They really help in some regions, but I really don't think I need them being considered during the culling stage for anything node that is more than about 5000 meters out.

What is the best way of managing occluder node lode?
Back to top
View user's profile Send private message Send e-mail
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 12148

PostPosted: Thu May 31, 2018 5:26 am    Post subject:
Large number of occluder nodes
Reply with quote

Hi David,

Which type of occluder are you talking about? osg::OccluderNode or
osg::OcclussionQueryNode? They are very different.

Also what is performance like without the occluders?

Robert.

On 30 May 2018 at 23:10, David Heitbrink <> wrote:
Quote:
I have a scene with a large number of occluder nodes. Its a large city scene, and most of the nodes are relatively small, like 10-50 meters wide, like 10-30 meters tall, in a database that is maybe 20 km x 20 km. I have 1000's of these. They are basically extracted semi-automatically. Most of them are simple just a 4 points.

My cull time is getting up to the 40ms range. They really help in some regions, but I really don't think I need them being considered during the culling stage for anything node that is more than about 5000 meters out.

What is the best way of managing occluder node lode?

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








------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
d_a_heitbrink (David Heitbrink)
User


Joined: 23 Sep 2013
Posts: 52

PostPosted: Thu May 31, 2018 3:00 pm    Post subject:
Reply with quote

I am using OccluderNode:
for each "building" in config file{
auto &pnt_pair = vecs[i];
osg::OccluderNode* onode = new osg::OccluderNode();
osg::ConvexPlanarOccluder* occl = new osg::ConvexPlanarOccluder();
osg::ConvexPlanarPolygon& polly = occl->getOccluder();

vector<osg::Vec3> pnts;
... get pnts from current building in custom config file
... most often 4 points


for (unsigned int j =0; j < pnts.size(); j++){
polly.add(pnts[j]);
}

onode->setOccluder(occl);
m_group->addChild(onode);
}

The performance without the occluders is bad. Basically the rendering of buildings is not bad, its pretty quick even without the occluders. Where we get in trouble is with the parked cars, pedestrians and various scene clutter. These are relatively small objects, and lots of them have transparency.

We want to add some form of OIT which should help us to avoid having some many depth sorted objects, but we are not there yet.
Back to top
View user's profile Send private message Send e-mail
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 12148

PostPosted: Thu May 31, 2018 4:44 pm    Post subject:
Large number of occluder nodes
Reply with quote

Hi David,

I wrote OccluderNode back in 2002 and haven't really touched it much
since, we get very few questions about it so I presume it isn't widely
used.

The original goal of OccludeNode was for a small number of large
occludes to be placed in city scenes to cull out data when the eye
point is at ground level i,e cars/pedestrians. The technique only
works well for large occluders relative to the size of objects being
culled.

So think an occluder geometry that goes down the centre of a block of
flats, ideally whole streets in one occluder geometry. Having lots of
separate occluders is costly performance wise and is ineffective at
culling as objects have to be wholly within a single occluder for it
to work.

There are plenty of other ways to optimize databases, I don't know how
good your database is to start with or what knowledge you have of the
various techniques you can use. Lots has been discussed over the
years about optimization so I won't start a lecture now

Robert.

On 31 May 2018 at 16:00, David Heitbrink <> wrote:
Quote:
I am using OccluderNode:
for each "building" in config file{
auto &pnt_pair = vecs[i];
osg::OccluderNode* onode = new osg::OccluderNode();
osg::ConvexPlanarOccluder* occl = new osg::ConvexPlanarOccluder();
osg::ConvexPlanarPolygon& polly = occl->getOccluder();

vector<osg::Vec3> pnts;
... get pnts from current building in custom config file
... most often 4 points


for (unsigned int j =0; j < pnts.size(); j++){
polly.add(pnts[j]);
}

onode->setOccluder(occl);
m_group->addChild(onode);
}

The performance without the occluders is bad. Basically the rendering of buildings is not bad, its pretty quick even without the occluders. Where we get in trouble is with the parked cars, pedestrians and various scene clutter. These are relatively small objects, and lots of them have transparency.

We want to add some form of OIT which should help us to avoid having some many depth sorted objects, but we are not there yet.

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








------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
d_a_heitbrink (David Heitbrink)
User


Joined: 23 Sep 2013
Posts: 52

PostPosted: Fri Jun 01, 2018 2:40 pm    Post subject:
Reply with quote

We do have a city scene at ground levels with lots of cars, pedestrian, construction zone clutter. The cars tend to be the worst as they can have up to 8 transparent object each from them. Large parking lots can have 500+ vehicles.

OK so it sounds like what we need to do is to try to combine occluder nodes the best we can. These were generated via a script and placed in the center of each building...we just have lots of building with alleys between them.

It also sounds like we will need to come up with some sort of paging/LOD scheme ourselves to remove nodes more than say 2500m from the camera.
Back to top
View user's profile Send private message Send e-mail
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 12148

PostPosted: Fri Jun 01, 2018 3:45 pm    Post subject:
Large number of occluder nodes
Reply with quote

Hi David,

Your cars could probably by simplified, such as by putting an LOD
above them and have one instance for far away with no, one just one
transparent part and a higher quality version. Using a texture atlas
is another trick you can use to enable you to merge separate
geometries.

Robert.

On 1 June 2018 at 15:40, David Heitbrink <> wrote:
Quote:
We do have a city scene at ground levels with lots of cars, pedestrian, construction zone clutter. The cars tend to be the worst as they can have up to 8 transparent object each from them. Large parking lots can have 500+ vehicles.

OK so it sounds like what we need to do is to try to combine occluder nodes the best we can. These were generated via a script and placed in the center of each building...we just have lots of building with alleys between them.

It also sounds like we will need to come up with some sort of paging/LOD scheme ourselves to remove nodes more than say 2500m from the camera.

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








------------------
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 -> 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 Mapping texture coordinates to a port... ijwolf8 General 0 Thu Oct 25, 2018 8:11 pm View latest post
No new posts the speed of PagedLOD create nodes snowlove General 0 Thu Sep 20, 2018 8:07 am View latest post
No new posts 'fatal error C1128: number of section... Jason Beverage General 2 Wed Apr 18, 2018 7:59 pm View latest post
No new posts GL3: non-GL3 version number: 1.0 pixelord General 12 Thu Oct 12, 2017 3:36 am View latest post
No new posts How to open shape file (.shp) or open... GISDeveloper General 0 Thu Oct 05, 2017 3:30 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