Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Problem with D3DFont Aliasing [modified]

Problem with D3DFont Aliasing [modified]

Scheduled Pinned Locked Moved C / C++ / MFC
helpgraphics
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Dustin Henry
    wrote on last edited by
    #1

    I am having a problem getting my D3DFonts to display antialiased. No matter what font I try to use, although some are better than others, it comes out all jagged around the edged like is is not being antialiased properly or at all. Font creation code:if (FAILED(D3DXCreateFont(m_pDirect3D->GetDevice(), //D3D Device iSize, //Font height 0, //Font width iWeight, //Font Weight 0, //MipLevels bItalic, //Italic DEFAULT_CHARSET, //CharSet OUT_DEFAULT_PRECIS, //OutputPrecision ANTIALIASED_QUALITY, //Quality DEFAULT_PITCH|FF_DONTCARE, //PitchAndFamily stFace, //pFacename, &font.m_d3dFont))) //ppFont) { return -1; }
    Font Display Code:m_pDirect3D->GetFontSprite()->Begin(D3DXSPRITE_ALPHABLEND); m_vFonts[state.m_nFont].m_d3dFont->DrawText(m_pDirect3D->GetFontSprite(), state.m_stText, -1, &rPos, state.m_dwTextJustify | DT_WORDBREAK, D3DCOLOR_RGBA(red,green,blue,iOpacity)); m_pDirect3D->GetFontSprite()->End();
    I have tried drawing both with a Direct3D sprite and by setting the first parameter to NULL. Any help is always appreciated. Thanks, Dustin P.S. Here is a link to what it looks like : http://img238.imageshack.us/img238/4011/fontsamplecl4.jpg[^] -- modified at 12:54 Wednesday 20th December, 2006

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups