Results 1 to 12 of 12
  1. #1
    seaplusplus's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    107
    Reputation
    4
    Thanks
    49
    My Mood
    Drunk

    Draw Text Function...

    I was board so I thought I'd release this...

    [PHP]
    void cDrawText(char *Text, int x, int y, char *FontName, D3DCOLOR FontColor, int FontWidth, int FontHeight, UINT Weight, IDirect3DDevice9* pDevice)
    {
    ID3DXFont *Font;
    D3DXCreateFontA(pDevice, FontHeight, FontWidth, Weight, 1, 0, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, ANTIALIASED_QUALITY, DEFAULT_PITCH | FF_DONTCARE, FontName, &Font);
    RECT FontR = {
    x,
    y,
    x+500,
    y+30
    };
    Font->DrawTextA(NULL, Text, -1, &FontR, DT_LEFT | DT_WORDBREAK, FontColor);
    }
    [/PHP]

  2. The Following 2 Users Say Thank You to seaplusplus For This Useful Post:

    Turbulence (03-17-2011),_Fk127_ (01-20-2011)

  3. #2
    whit's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Posts
    7,170
    Reputation
    490
    Thanks
    2,252
    This is more complicated then it should be..

    And theres like 100 already released

  4. #3
    _Fk127_'s Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    724
    Reputation
    16
    Thanks
    208
    My Mood
    Bitchy
    But he actually made this so...



    Put this image in your signature if you support HTML5 development!

  5. #4
    ac1d_buRn's Avatar
    Join Date
    Aug 2009
    Gender
    female
    Location
    CA Source Section
    Posts
    3,406
    Reputation
    157
    Thanks
    3,991
    My Mood
    Flirty
    Why the hell would i use this and create the font every time that function is called?

  6. The Following User Says Thank You to ac1d_buRn For This Useful Post:

    D15H (02-07-2011)

  7. #5
    EvilCow's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    75
    Reputation
    10
    Thanks
    0
    My Mood
    Twisted
    Quote Originally Posted by ac1d_buRn View Post
    Why the hell would i use this and create the font every time that function is called?
    Because you can?


    Regards,
    EvilCow

    ----------------------------------------------------------------------------------------------------------------
    The ocean is full of life. Yet it is not life as we know it. To survive there, we must release our hold on land. Accept a new way to live. So it is with the death. The soul must accept it's departure from the body. If it can't, it will be lost

    Thank Me If I Helped!


    ------♥♥------Put This
    -----♥♥♥-----In Your
    ----♥♥-♥♥----
    Sig If
    ---♥♥---♥♥---You Know
    ---♥♥---♥♥---Someone
    ---♥♥---♥♥---Who Died
    ----♥♥-♥♥----Or Is
    -----♥♥♥-----
    Suffering
    ----♥♥-♥♥----From
    ---♥♥---♥♥---Cancer

  8. #6
    _Fk127_'s Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    724
    Reputation
    16
    Thanks
    208
    My Mood
    Bitchy
    cause then ppl dont have to do it themselves :?



    Put this image in your signature if you support HTML5 development!

  9. #7
    flameswor10's Avatar
    Join Date
    Jul 2009
    Gender
    male
    Posts
    12,528
    Reputation
    981
    Thanks
    10,404
    My Mood
    In Love
    What's it looks like :S
    No I do not make game hacks anymore, please stop asking.


    Been MPGH Minion: 6 July 2011 - 1 August 2012

  10. #8
    mmbob's Avatar
    Join Date
    Dec 2009
    Gender
    male
    Location
    ja
    Posts
    655
    Reputation
    70
    Thanks
    1,156
    My Mood
    Bitchy
    Noice memory leak.

  11. The Following 6 Users Say Thank You to mmbob For This Useful Post:

    -Stephen (01-21-2011),ac1d_buRn (01-21-2011),Crash (01-21-2011),IcySeal (01-21-2011),markoj (01-21-2011),topblast (01-21-2011)

  12. #9
    IcySeal's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Posts
    300
    Reputation
    34
    Thanks
    148
    My Mood
    Amused
    Holy fuck, I have never seen anything liek this. Way to go.

  13. The Following User Says Thank You to IcySeal For This Useful Post:

    seaplusplus (01-21-2011)

  14. #10
    seaplusplus's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    107
    Reputation
    4
    Thanks
    49
    My Mood
    Drunk
    Quote Originally Posted by IcySeal View Post
    Holy fuck, I have never seen anything liek this. Way to go.
    Thanks! Check your PM's...

  15. #11
    Crash's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    JAville
    Posts
    2,889
    Reputation
    163
    Thanks
    3,289
    My Mood
    Sleepy

  16. The Following 3 Users Say Thank You to Crash For This Useful Post:

    -xGhost- (01-21-2011),ac1d_buRn (01-21-2011),markoj (01-21-2011)

  17. #12
    topblast's Avatar
    Join Date
    Mar 2010
    Gender
    male
    Location
    Far from around you Programmer: C++ | VB | C# | JAVA
    Posts
    3,607
    Reputation
    149
    Thanks
    4,922
    My Mood
    Cool
    Quote Originally Posted by mmbob View Post
    Noice memory leak.
    Yea he did not release it. Yea he can create the font every Frame as much times as he want but the memory leak will LAG LIKE HELL. driving the computer to a halt.
    I just like programming, that is all.

    Current Stuff:

    • GPU Programmer (Cuda)
    • Client/Server (Cloud Server)
    • Mobile App Development