mav on renderworld()
Blitz3D Forums/Blitz3D Programming/mav on renderworld()
| ||
In my texpaint program, I get an error on RenderWorld() So I wrote a small test version using different methods, but it keeps giving the same error. Is there something I'm doing wrong ? I would appreciate it if someone could try to run this code and tell me if the bug occurs on their machine. It takes a minute for the bug to appear. Has someone experienced the same problem ? I've read a few posts on this error, but in that cases people made too many triangles on a surface. When I made a version that handles single surface meshes, there is no bug. Same goes for the original texpaint by birdie. So I think the problem could have something to do with using PickedSurface(). |
| ||
Works fine for me. |
| ||
Thanks skidraces, I appreciate it. The trouble with this bug is that is takes really a while for it to appear. I've traced the bug using a counter and speeded the example up using "Flip False". When counter reaches 1995, the bug appears. |
| ||
If there is a chance a texture is missing you probably want to test if tex%=0 before you go and lock / setbuffer the texture, if that doesn't help comment out the call to oval, if that fixes it it sounds very much like a driver bug... If still no, then can you remove the millisecs() dependency and use an incrementing variable and repost so I am running the same test with the same numbers as yourself. |
| ||
I think it is strange that I've had this similair problem in two versions. I tested it on another PC, and there it gives an error, too. Removing the oval did solve the problem! Also when I removed the two 'SetBuffer' commands: no error. The bug appears after a fixed number of frames. PC1:2330 PC2:3200 It doesn't matter where I enter the 'loop'. Maybe it is a problem with releasing something ? All other bugs with RenderWorld() involved some kind of memory leak, for instance too much triangles on a surface. GetSurfaceBrush creates a new brush, but the texture applied to it, is it a copy too ? I checked if the handle of this returned texture is the same as the original handle, and it is the same. |
| ||
I still think it is a bug. Sigh .. I will find a workaround. |
| ||
it is not crashing to me, but sometimes blitz' renderworld crashes on to many triangles! |
| ||
Hmm. Thanks for testing it, oh child of the devil. I think Skidracer is right then, about it being a driver problem. I have a NVidia board on both my pc's. Thanks again Skid and sorry I had my doubts. I can avoid the error by creating a new texture and draw on that. |