Hello,
I was not happy with the performance using BaseDraw::LineStripBegin() / BaseDraw::LineStrip() / BaseDraw::LineStripEnd() to draw thousands of strands on the viewport, so I tried using GlProgramFactory
and GlVertexBuffer
from gl.h, exemplified on the sdk source gl_test_object.cpp. The performance improved was amazing, viewport fps raised up to 3 times.
But those functions are marked as undocumented, and I hope that's very different from the private, that shall never be commented, because some issues arised that I'm unable to solve.
First, bd->SetDrawParam( DRAW_PARAMETER_LINEWIDTH, 2 );
does not work when drawing with DrawSubBuffer()
.
DRAW_PARAMETER_LINEWIDTH
is marked in the docs as (OpenGL only)
, but actually looks like is the inverse.
How can I set like width for DrawSubBuffer()
?
What OpenGL does DRAW_PARAMETER_LINEWIDTH
refers to?
And some lines seem broken, with gaps in between, usually on concave surfaces. Looks like some depth precision problem.
How to control depth read/write using those functions?