VertexBuffer.create event question in Managed c#

Started by
-1 comments, last by TheSilverHammer 16 years, 6 months ago
According to some books I have, the vertex buffers are re-created on device reset, which is supposed to happen even if you resize the device window. For me, this event never seems to fire although all my verts seem to be preserved. The question I have, since I can't get this event to trip, is if references to the vertex buffer are lost or not? ie: SomeClass { VertextBuffer VB; Init() { VB = new VertexBuffer(..); VB.created += new eventhandler(...); } void onVBCreated(...) { ... }; } When my object 'inits' it assign VB to a new vertex buffer. However, when a device resets it calls the onVBCreated event because managed directX9 'recreats' the buffer for you. The question I have, is if VB points to the new VB or is pointing at something 'dead' ?

This topic is closed to new replies.

Advertisement