CreateTextureFromSurface()

Started by
0 comments, last by Gandalf 24 years, 5 months ago
I create a texture with a call to the
function CreateTextureFromSurface(). Then
I blit to the surface and make a new call
to the CreateTextureFromSurface() function,
but with a new texture as argument. Now the
texture I first created is changed! Very bad!

My question is: Is the surface connect to the texture in this case?

------------------
Gandalf the White

Gandalf the Black
Advertisement
Yes, the texture's just a pointer to the surface with some extra information for Direct3D thrown in. You need a separate surface for every separate texture. This makes more sense with the DirectX 7 API since they dumped the texture interface altogether and now just use surfaces.

This topic is closed to new replies.

Advertisement