Jump to content
  • Advertisement
Sign in to follow this  

VertexBuffer.create event question in Managed c#

This topic is 4094 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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' ?

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!