-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Memory leak after unreasonable ammount of DrawOverlayInGame calls and large ImageElement #81
Comments
I'd advice you to read this issue: #80 |
@Vadkarika2 When you say redraw, do you mean sending a complete new overlay to the target? Can you please provide a quick and simple reproducible snippet for the scenario? |
In my heavily modified version of this project, I wrap the code in DXSprite.cs -> BeginBatch(ShaderResourceView texSRV) with a using statement:
It eliminated one of a few leaks I encountered. My overlay changes each time I send it, and @justinstenning , I think this is what @Vadkarika2 is doing. |
Hi! Thanks for the help! What I mean by redraw is I send a new overlay, yes... I'll try out what @jazzup suggested, and post an update on the results! Thanks again, |
Yep! This fixes my issue, thanks for the suggestion! |
Merged, thx |
Hi!
I've been using this library for a couple of days now, and I came across what I think is a realy small memory leak somewhere...
After calling the DrawOverlayInGame method for more than 70,000 times, a memory leak occurs, and becomes more noticable with each redraw...
At 50,000 redraws the memory usage of the target app is 205.4MB, but at 100,000 redraws, it jumps up to 555.1MB, and after that, it goes out of hand, and at 110,000 redraws the memory usage jumps to 1,2GB...
The overlay contains 1 image element, which is being changed every frame, and the size of it is 1920x1080...
I'd realy appreciate if someone could look into this, this is a realy cool library!
Thanks,
M
The text was updated successfully, but these errors were encountered: