Re: [osg-users] Large number of occluder nodes

2018-06-01 Thread Robert Osfield
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:
> 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
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Large number of occluder nodes

2018-06-01 Thread David Heitbrink
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





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Large number of occluder nodes

2018-05-31 Thread Robert Osfield
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:
> I am using OccluderNode:
> for each "building" in config file{
> auto _pair = vecs[i];
> osg::OccluderNode* onode = new osg::OccluderNode();
> osg::ConvexPlanarOccluder* occl = new osg::ConvexPlanarOccluder();
> osg::ConvexPlanarPolygon& polly = occl->getOccluder();
>
> vector 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
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Large number of occluder nodes

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

vector 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





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Large number of occluder nodes

2018-05-30 Thread Robert Osfield
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:
> 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
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Large number of occluder nodes

2018-05-30 Thread David Heitbrink
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





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org