释放强制终止应用程序留下的 Direct3D 资源

发布于 2024-09-16 05:38:45 字数 270 浏览 1 评论 0原文

我正在开发 Direct3D 应用程序,有时需要通过调试器强制终止应用程序。应用程序以这种方式终止几次后,Direct3D 在尝试创建新设备时会报告“视频内存不足”错误。目前,我正在通过将显示分辨率切换到 800x600 并返回到之前的分辨率来解决此问题,希望能够“重置”视频内存。 99% 的时间都有效。但如果有一个简单的实用程序(也许是一个命令行应用程序)通过显式释放视频内存来快速重置我的显卡和 Direct3D 堆栈,那就太好了。

如何释放强制终止 Direct3D 应用程序留下的视频内存和其他资源?

I'm working on a Direct3D application and I sometimes need to terminate the application forcefully via the debugger. After the application has been terminated in this way a couple of times, Direct3D reports an "Out of video memory" error when attempting to create a new device. Presently I am working around this by switching my display resolution to 800x600 and back to previous resolution in the hope of "resetting" video memory. It works 99% of the time. But it would be nice to have a simple utility -- a command line app, perhaps -- to quickly reset my graphics card and Direct3D stack by releasing video memory explicitly.

How can I free video memory and other resources left behind by a forcefully terminated Direct3D application?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦一生花开无言 2024-09-23 05:38:45

这是一个驱动程序错误。当进程退出时,驱动程序应该释放内存。如果没有这样做,那么您需要更新您的驱动程序。如果仍然不起作用,您需要将复制案例发送给制作您的卡的 IHV。

This is a driver bug. The driver should release the memory when the process exits. If it isn't doing so then you need to update your driver. If that still doesn't work you need to send a repro case to the IHV that made your card.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文