Sign in to follow this  
jad_salloum

texture problem

Recommended Posts

Hi,

The problem firstly is that you will need to expand on your post quite a bit before people are willing to help. People won't know what you mean.

That aside, i shall ask.

Can you expand please then i can help. Do you simply mean how to write text to a DirectX window?

ace

Share this post


Link to post
Share on other sites
hi acelover , no i don't mean writting text on a window , i will explain in details ::

i have an X file that has a texture covering it , so i want to write some text on its texture not on the window, so if the X file is for putting a name on it , the name should stick on the texture even if the x file is animated and make movements . i think that i need something called ((render text to texture)) but i don't know how to do it thanks for ur help

Share this post


Link to post
Share on other sites
paste some code plzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz

Share this post


Link to post
Share on other sites
Quote:
Original post by jad_salloum
paste some code plzzzzzzzzzzzzzzzzzz[...]zzzz

g_pDevice->SetRenderTarget(pTexture->GetSurfaceLevel(0));



EDIT:
Ok, sorry for flaming.
The full version could be:

ID3DXSurface *pSurf = pTexture->GetSurfaceLevel(0);
ID3DXSurface *pPrevRenderTarget = g_pDevice->GetRenderTarget(0);
g_pDevice->SetRenderTarget(0, pSurf);
// Render as if you were rendering to the screen.
// ...
g_pDevice->SetRenderTarget(0, pPrevRenderTarget);
pPrevRenderTarget->Release();
pSurf->Release();

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this