Hi,
I was going through forum but could not find an answer for a simple question -
how to detect if current system/graphic card supports hardware instancing? I
want to know this to provide a proper factory for scene objects to provide
maximum performance (HW if possible, software otherwise).
Hi,
I have implemented the simplest fragment shader applying only particular color
to my primitives as this was sufficient. However now I want to create a
composition of a simple osg::ShapeDrawable for a osg::Box and my instanced
material (spheres), where Box should be semitransparent and so
[quote=SMesserschmidt]
When you use instanced drawing you cannot have correct semi-transparent
objects, as there is no sorting involved.
One option is to sort your instanced obejcts in every frame or to use some
order independent transparency approach.
[quote]
Could You provide me avaiable
Hi Sebastian ,
Well, I need instancing as I render about 1M spehers presenting material atoms
structure. The Box I want to add is just a marker for a part of the whole
material, so user can focus easier on it. Moreover, box will always contain
instanced spheres inside, so the order is somehow
Hi Sebastian,
Thank You for Your suggestions. I will try their various combonations to
distinguish which one gives the closest results to what I wanted to achieve.
...
Thank you!
Cheers,
Mateusz
--
Read this topic online here:
Jordi Torres wrote:
Did you tried to add normals to the instaced geometry?
Yes, I add normals. Do You think I should modify fragment shader to
calculate light there? If I skip fragment shader at all then speheres are
always black independently how would I try to apply some
Ok, Jordi solution wokrs like a charm, I had only to disable culling on
drawable, so that its all hardware instanced objects are not culled when
original is not visible. I have another problem now - how to apply Material and
Light to such a drawable so that it is populated with hardware
, if you need more
you should use a TextureBufferObject. I've attached a simple example getting
postions from a texture 1D. The TransferFunction used is not necessary.
Hope it helps.
2013/6/20 Mateusz Janiak ()
Hi,
I have a large static scene to render - it will not change
Hi,
I have a large static scene to render - it will not change in time. It can
contain even 1M spheres representing atoms in a particular material. I have
read a lot about instanced drawing and went through examples:
osgdrawinstanced
osgshaders
but I can not to figure out how can I pass world
9 matches
Mail list logo