What is the difference between CreateCompatibleRenderTarget and CreateHwndRenderTarget

StackOverflow https://stackoverflow.com/questions/18965221

  •  29-06-2022
  •  | 
  •  

문제

I am just confused about the difference since, we can just make a bitmap the size of the window and then draw the image onto the window?

도움이 되었습니까?

해결책

The difference is in the name: CreateCompatibleRenderTarget does just that in that it creates a render target that is compatible with the current display settings. CreateHwndRenderTarget conversely creates a RT that simply renders to a window. So it is not set up the same way as the compatible target.

What is a render target?

Even though that talks about XNA, most of the primitive information there is agnostic of even DirectX and simply discusses the idea of a render target.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top