View draw_lines bug
-
Hi.
Been pushing a Tools view.draw methods pretty hard and noticed that when exeding a certain
amount of geometry, BUGSPLAT!
Very consistently to.After a lot of testing I found out it was the draw_lines method that was causing it.
Switching to GL_LINES solved the problem immediately and I could push it past the double of geometry without crash. Then other issues came alongJust a report.
-
Since the draw_points (kills next operation) bug, I haven't used anymore the API's wrapper methods but use those with GL constants. I feel it keeps my code look more consistent.
Did you find out which is the maximum of points that causes problems? Is there a maximum for
draw
/draw2d
with GL constants (which directly interfaces with OpenGL)? I'd rather think a wrapper would take care of such limitations than introduce new ones. -
Maybe a few more observations while I'm at it. This is purely speculative based on impressions. And also dependent on Graphic card?
The subject may have been described earlier, I havent seen it.Changing colors seams to be immediate. Even on very large collections, assuming you can get a hold on the objects easily.
I also get the impression GL_LINES are harder to render than GL_TRIANGLES.
There are sideeffects that I don't see using faces only when using plenty of geometry. Like Groups or components also getting affected by orbiting, like view.suspend. They then become wireframe bounds.
And won't behave like normal even if turning the Tool off.Maybe it has to do on amount of elements. So it's not dependent on how much space it takes up on the screen then. Which may influence the decision if one has to decide between showing wireframe OR Faces for performance reasons.
-
So far I have not used any draw2d methods.
@unknownuser said:
Did you find out which is the maximum of points that causes problems?
I have come back from 3 million points without crash.
But that was really sluggish. My card start to work hard at around 20K points.I have not had any problems with points. There pretty fast. Although, I imagine you are more picky than me since you want to create nice widgets for your framework
I have seen the reports about deleted commands and experienced it myself. But when ordering them as recommended it seams to work.Could there be a speed difference depending on what kind of pointmode one use ?
I use 3 (+) with 10. So it looks like a point.Edit: Removed some irrelevant stuff..
Around this amount made draw_lines crash:
48 000 edges
32 000 faces
148 000 PointsThis was in an empty scene. So only view.draw items where displayed.
-
We are currently working on fixing a crash in view.draw* where incorrect number of points for the drawing operation will cause a crash. Maybe that's what you guys are experiencing?
If anyone can post example code it would be much easier to determine what we're dealing with here.
-
@unknownuser said:
where incorrect number of points
No. I usually get an argumenterror in case that happends. I don't think that is it.
It's difficult to extract specific code related to this, maybe later if I find the time to build a testcase. You could probably test this quite easily. In my case it was simply a matter of adding a lot of edges. Over 20K entities in the draw commands, then BOM!
Bottom line is the crash does not occour when using GL_LINES.
So for me all is fine.. -
@jolran said:
Bottom line is the crash does not occour when using GL_LINES.
So for me all is fine..We'd really like to close down any causes of crashes. So please send us examples if you come across it.
Advertisement