/ osgmemorytest

OpenSceneGraph

Documentation

osgmemorytest

This example is written with the intent of testing out the capabilities of our hardware/drivers/OS's to allocate lots of windows/pbuffers on the window manage side, and lots of FBO's, texture and geometries on the OpenGL object side.

This example has a couple of specific uses - first up it's educational - we can quickly test just how many objects we can throw at our systems and expect them to run, secondly its a diagnostic tool - so when things go wrong we can use it too recreate the problems we see in our own apps but with a small focused code set, finally it's a way of comparing capabilities across platforms/drivers - which in turn might lead back to diagnostics on problem platforms.
Be warned that by pushing things too far, you can start stalling the machine or even crashing it in extreme cases where the OpenGL driver is misbehaving.

Usage examples

1) How many windows can I open?
Try to open 1000 windows:
osgmemorytest --window -c 1000

2) How many pbuffers can I open?
Try to open 1000 pbuffers:

osgmemorytest --pbuffer -c 1000

3) How many texture objects can I open?
Try to open 10000 256x256 RGB textures:

osgmemorytest --texture 256 256 -g 10000

4) How many display listed based geometry objects can I open?
Try to open 10000 32x32 geometry tile:

osgmemorytest --geometry 32 32 -g 10000

5) How many vertex buffer object based geometry objects can I open?
Try to open 10000 32x32 geometry tile:

osgmemorytest --geometry-vbo 32 32 -g 10000

6) How many vertex array geometry objects can I open?
Try to open 10000 32x32 geometry tile:

osgmemorytest --geometry-va 32 32 -g 10000

7) How many display listed geometry objects can I open?
Try to open 1000 256x256 fbo's

osgmemorytest --fbo 256 256 -g 1000

8) How many display listed geometry objects can I open?
Try to open 1000 1024x1024 fbo's

osgmemorytest --fbo 1024 1024 -g 1000

9) How many display listed geometry objects can I open?
Try to open 1000 2048x2048 fbo's

osgmemorytest --fbo 2048 2048 -g 1000