Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Render Text to Image without GetImage?

Author
Message
Gunslinger
16
Years of Service
User Offline
Joined: 29th May 2007
Location:
Posted: 22nd Mar 2014 16:04
Hello,
i want to create a damage amount effect (You know, like in RPGs or MMOs where the damage amount shows up on a hit).
So my plan is to texture a plain with the damage value.

How can i make this?

One way would be
- Draw Text
- Get Image at this position
- Texture Object with this image

but i dont want to use getimage, is there another way?

Thanks.
Rudolpho
18
Years of Service
User Offline
Joined: 28th Dec 2005
Location: Sweden
Posted: 22nd Mar 2014 17:55
Use a bitmap font system; those inherently tend to draw the resulting text to an image (usually through blitting rather than rendering though).
Using the built-in text functionality of DGDK, no, I don't think there's any other way than that, although you can get get a 3D coordinate's representation in screen space and just position your (normal 2D) text accordingly.


"Why do programmers get Halloween and Christmas mixed up?"
WickedX
15
Years of Service
User Offline
Joined: 8th Feb 2009
Location: A Mile High
Posted: 6th May 2014 21:51
Now you can set a camera to an image and use dbSetCurrentBitmap(-Camera Number) to render directly to the camera surface. You will need to download the Unofficial Update.

Login to post a reply

Server time is: 2024-04-24 04:44:17
Your offset time is: 2024-04-24 04:44:17