GDI +是否支持图形加速? [英] Does GDI+ support graphics acceleration?

查看:137
本文介绍了GDI +是否支持图形加速?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用C ++和Win API为Windows平台编写屏幕保护程序.要渲染图形,我使用的是GDI +,但是问题在于渲染带有少量动画(淡入和淡出)的png非常占用CPU资源".

I'm trying to write a screensaver for a Windows platform using C++ and Win APIs. To render graphics I'm using GDI+, but the issue is rendering png's with some small amount of animation (fade-in and -out) becomes very "CPU heavy."

所以我想知道是否有办法为GDI + API启用GPU加速?如果不可能,那么我可以从支持GPU加速的非托管代码(除了OpenGL或DirectX)中使用某些东西吗?

So I was wondering if there's a way to enable GPU acceleration for GDI+ APIs? And if it's not possible, is there something that I can use from a non-managed code that supports GPU acceleration (apart from OpenGL or DirectX)?

推荐答案

不是. GDI主要涉及内存位图的处理.如果您需要更多高级功能,请使用Direct3D/2D.

Nope. GDI is mostly about manipulation of in memory bitmaps when it comes down to it. If you want more advanced features, use Direct3D/2D.

这篇关于GDI +是否支持图形加速?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆