Skip to main content
deleted 9 characters in body
Source Link
János Turánszki
  • 3.1k
  • 3
  • 18
  • 24

a rather quick question, I am starting on implementing rendering with deferred context into my game engine, and came across a heavy memory leak when recording command lists on my deferred contexts. Because every frame I would go like this: DeferredContext[THREAD]->FinishCommandList( 0,&commandLists[THREAD] ), it would eat up RAM, so I Release them every time, like:

if(DeferredContext[THREAD]commandLists[THREAD]){
 DeferredContext[THREAD]commandLists[THREAD]->Release();
 DeferredContext[THREAD]commandLists[THREAD] = NULL;
}

I previously only released objects when they wouldn't be used any more, so I thought there would be a more optimized way of handling this? (Like mapping dynamic *ID3D11Buffers for example?)

a rather quick question, I am starting on implementing rendering with deferred context into my game engine, and came across a heavy memory leak when recording command lists on my deferred contexts. Because every frame I would go like this: DeferredContext[THREAD]->FinishCommandList( 0,&commandLists[THREAD] ), it would eat up RAM, so I Release them every time, like:

if(DeferredContext[THREAD]){
 DeferredContext[THREAD]->Release();
 DeferredContext[THREAD] = NULL;
}

I previously only released objects when they wouldn't be used any more, so I thought there would be a more optimized way of handling this? (Like mapping dynamic *ID3D11Buffers for example?)

a rather quick question, I am starting on implementing rendering with deferred context into my game engine, and came across a heavy memory leak when recording command lists on my deferred contexts. Because every frame I would go like this: DeferredContext[THREAD]->FinishCommandList( 0,&commandLists[THREAD] ), it would eat up RAM, so I Release them every time, like:

if(commandLists[THREAD]){
 commandLists[THREAD]->Release();
 commandLists[THREAD] = NULL;
}

I previously only released objects when they wouldn't be used any more, so I thought there would be a more optimized way of handling this? (Like mapping dynamic *ID3D11Buffers for example?)

Tweeted twitter.com/#!/StackGameDev/status/370653264351887360
Source Link
János Turánszki
  • 3.1k
  • 3
  • 18
  • 24

D3D11 Deferred Context CommandList Reset

a rather quick question, I am starting on implementing rendering with deferred context into my game engine, and came across a heavy memory leak when recording command lists on my deferred contexts. Because every frame I would go like this: DeferredContext[THREAD]->FinishCommandList( 0,&commandLists[THREAD] ), it would eat up RAM, so I Release them every time, like:

if(DeferredContext[THREAD]){
 DeferredContext[THREAD]->Release();
 DeferredContext[THREAD] = NULL;
}

I previously only released objects when they wouldn't be used any more, so I thought there would be a more optimized way of handling this? (Like mapping dynamic *ID3D11Buffers for example?)