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 / How do I output text at an angle?

Author
Message
Stucky
15
Years of Service
User Offline
Joined: 11th Apr 2009
Location:
Posted: 25th May 2009 09:27
Kind of doubt this is possible myself, but I'm wondering if there might be a way to output text at an angle using the commands in Dark GDK?
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 25th May 2009 16:50
Do you want the entire text at an angle with the letters still parallel to each other or do you want the letters upright while the text sort of stair-steps up or down?

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Stucky
15
Years of Service
User Offline
Joined: 11th Apr 2009
Location:
Posted: 26th May 2009 00:27
I want the whole text at an angle. Just like how it is in this picture.
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 26th May 2009 01:43
This is untried, but can you create a temporary bitmap, write the text to the bitmap, copy it to an image then rotate the sprite used to display the image?

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Stucky
15
Years of Service
User Offline
Joined: 11th Apr 2009
Location:
Posted: 26th May 2009 06:58
I don't see why that wouldn't work. I'll give it a try, thanks.
Diggsey
18
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 26th May 2009 13:38
If you need to update the text in real-time, it will be far faster to create a render target using 'dbSetCameraToImage', and then use 'dbSetCurrentBitmap' with the negative image number. Then whatever you draw will go straight onto the image until you change the current bitmap back to 0. You can use 'dbSetSpriteTextureCoords' to display only a portion of the image. You can use 'dbPasteSprite' to make it not appear above everything else too, and it also means you can reuse the same sprite for all your text.

Login to post a reply

Server time is: 2024-11-05 18:58:29
Your offset time is: 2024-11-05 18:58:29