Hello Carsten,

many thanks for your answer, it helped me a lot! Some comments below...

Carsten Neumann napsal(a):
>       Hello Tomas,
>
> Tomas Hnilica wrote:
>   
>> Hello all OpenSG users,
>>
>> I am new to OpenSG so sorry for "stupid" quesitons in advance.
>>
>> I am working on multiplatform visualization application using FOX 
>> library for GUI. I have an openGL window there with basic scene 
>> functions like lights, cameras, scene manipulations,selection... (FOX 
>> has such class) so I am able to display and work with my models.
>> The problem is, that the models can be very large - up to 15 milions of 
>> tetrahedrons - and the performance is very bad - there is no 
>> optimization, no scenegraphs, just traversing an array of  "tetrahedron 
>> objects" and issuing openGL commands (of course many glBegin,glEnd).
>>
>> So I was looking for some optimization algorithms and have found OpenSG 
>> which looks very very good.
>>
>> So I would like to ask you:
>> - will openSG speed up the graphics and how? In the StarterGuide i red, 
>> that graph operators will do the job - minimize glBegin,glEnd  commands, 
>> optimize the scene graph, culling and so on...
>>     
>
> as always, the answer is "it depends" ;) If all of your scene is on
> screen with little overdraw there is not much that can be done (expect
> getting faster hardware). But if parts of your scene are off-screen or
> there is lots of overdraw or you do many switches between a set of
> materials OpenSG can improve performance - it does frustrum culling,
> occlusion culling and attempts to minimize OpenGL state changes.
>
>   
>> - is it better to use openSG since I only need graphics optimization or 
>> is it better to implement such optimizaion algorithms? I thnik openSG 
>> offers me matured functionality for displaying text, legends, selection 
>> highlighting, etc...On the other hand writing optimization algorithms 
>> would be something like reinventing the wheel...but more customized.
>>     
>
> Hm, hard to say for me. Maybe if you tell us what optimizations you need
> we can attempt to make a guess, but in the end you will likely have to
> make that decision yourself, since you know your requirements and data
> structures best.
>
>   
OK, in very easy way: I have an array of nodes (points - holds it's 
x,y,z position) and array of elements. Element is typically tetrahedron 
(holds pointers to 4 nodes which it constitst of), but can be any other 
geometric figure.
There is no structure in the model - just flat arrays.I need to be able 
to set color to every single element.  And what I want is to draw it all 
as fast as possible.
Currently most stupid draw is done - go through all elements and draw 
them - set color, glBegin, draw element (tetrahedron is made like 
trianglestrip), glEnd....
>> - How is it with memory usage? Since the models are big, i must be 
>> memory efficient. I think the way openSG users work with data is: read 
>> data and put them into nodes in the tree, when picking (or working on 
>> other way) traverse the tree. No additinal data structures are needed. 
>> Am I right? Currently I have data in classes that reflect the meaning of 
>> the data (ie not only to display, but also to calclate something...). 
>> How to split the data so the original purpose will remain and not to 
>> double the data for openSG graphs?
>>     
>
> At the very bottom geometry data is basically held in an std::vector,
> which is wrapped in something called a OSG::GeoProperty. Now, if your
> non-rendering algorithms can work on that, you don't need to duplicate
> data. Otherwise it depends on what data structures you need and how
> difficult it is to keep things in sync, but I can't give you any tips
> there from what you have told us, sorry.
>
>   
That is enough, many many thanks! :)
>> - LOD: in starterguide there is an example where 3 models had to be 
>> created. Is there any chance to use such optimization like LOD that 
>> creates the less-detailed models itself from origin(=full detail) data?
>>     
>
> It can be done, but nobody has implemented it.
>
>   
Well, then it is not very usable for many applications :(.
>> - I tested ParaView (based on VTK) for performance and the graphics 
>> speed on my models was good. Do you think openSG can have comparable 
>> speed? Are there any comparsions available?
>>     
>
> Sorry, I don't know ParaView so I can't comment on this.
>
>       Hope it helps,
>               Carsten
>   
Helped, thank you very much Carsten!

Tomas
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys - and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Opensg-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/opensg-users
>
>   


-- 
S pozdravem
     Mgr. Tomas Hnilica

=================================
e-mail: [EMAIL PROTECTED]
tel.: +420 604 214 284
=================================


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to