How i can to render Spanish Text using CD3DFONT?

How i can to render Spanish Text using CD3DFONT?

Post by [Over » Tue, 08 Jul 2003 17:31:53



Hello.

I want to render text using CD3FONT but the custom code
dont know the spanish character
like "?","?",",,,,". Can i draw this character with
this code?. How i can?.

Please HELP ME.

 
 
 

How i can to render Spanish Text using CD3DFONT?

Post by Laurent Testu » Tue, 08 Jul 2003 23:36:06


You need to modify the source code so that the texture is generated for the
full character set. CD3DFont stops at ascii code 127. Do also some similar
changes when drawing text. The texture will be much bigger. Check device
caps for tex size, use scaling if too big.

I made these changes for the DX8 version, that was easy. I plan to do the
same for DX9.
--
Laurent TESTUD - http://jeux-directx.com/ ::: http://LaFaqMFC.com/


Hello.

I want to render text using CD3FONT but the custom code
dont know the spanish character
like "?","?",",,,,". Can i draw this character with
this code?. How i can?.

Please HELP ME.

 
 
 

1. After drawing text using CD3DFont class, images are not rendering

Hi,
  I'm using DirectX 8 for drawing some images and text.
And I have a problem, that after drawing text using
CD3DFont class (provided by DX8 SDK), the images coming
after do not draw. All images before drawing text draw
fine. I'm sure, that DrawPrimitive is executed for images
coming after text. I think, there should be some setting,
which may not come back after drawing text. What setting
should I set, in order to be sure, that images will draw?

This is my setting for drawing images:

// Samotne renderovani
_Device->BeginScene();
_Device->SetTexture(0, Texture);
_Device->SetRenderState( D3DRS_ALPHABLENDENABLE, true);
_Device->SetTextureStageState(0, D3DTSS_ALPHAOP,  
D3DTOP_BLENDDIFFUSEALPHA);

_Device->SetTextureStageState( 0, D3DTSS_ADDRESSU,
D3DTADDRESS_CLAMP );
_Device->SetTextureStageState( 0, D3DTSS_ADDRESSV,
D3DTADDRESS_CLAMP );
_Device->SetTextureStageState(0, D3DTSS_MAGFILTER,
D3DTEXF_LINEAR );
_Device->SetTextureStageState(0, D3DTSS_MINFILTER,
D3DTEXF_LINEAR );

switch ( Render->BlendMode() )
{
case BLMODE_ZERO:
_Device->SetRenderState( D3DRS_SRCBLEND, D3DBLEND_ZERO);
_Device->SetRenderState( D3DRS_DESTBLEND, D3DBLEND_ZERO);
case BLMODE_ONE:
_Device->SetRenderState( D3DRS_SRCBLEND, D3DBLEND_ONE);
_Device->SetRenderState( D3DRS_DESTBLEND, D3DBLEND_ONE);
case BLMODE_SOURCECOLOR:
_Device->SetRenderState( D3DRS_SRCBLEND,
D3DBLEND_SRCCOLOR);
_Device->SetRenderState( D3DRS_DESTBLEND,
D3DBLEND_INVSRCCOLOR);
case BLMODE_DESTCOLOR:
_Device->SetRenderState( D3DRS_SRCBLEND,
D3DBLEND_DESTCOLOR);
_Device->SetRenderState( D3DRS_DESTBLEND,
D3DBLEND_INVDESTCOLOR);
default:
_Device->SetRenderState( D3DRS_SRCBLEND,
D3DBLEND_SRCALPHA);
_Device->SetRenderState( D3DRS_DESTBLEND,
D3DBLEND_INVSRCALPHA);

_Device->SetVertexShader(VertexFVF);
_Device->SetStreamSource(0, Buffer, sizeof(v[0]) );

_Device->DrawPrimitive(D3DPT_TRIANGLESTRIP, 0, 2);

_Device->EndScene();

Thank you for help.

2. How to iterate though all permutations of a set?

3. Pixel debris when using Large CD3DFont

4. ??which mid-high end printer??

5. using a callback node to do OpenGL rendering and render culling

6. Looking for basic lighting websites

7. CD3DFont and ID3DXFont

8. printon dot matrix printer

9. bug in CD3DFont ???

10. question about cd3dfont (smooth the edges)

11. cd3dfont, and uninstalled font

12. Large Fonts and CD3DFont and texture limits

13. CD3DFont question