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.

DarkBASIC Discussion / Semi-transparent

Author
Message
Furiousuk
23
Years of Service
User Offline
Joined: 10th Jan 2003
Location: United Kingdom
Posted: 30th Mar 2003 20:53
I'm writing a 2D program and I want to be able to write text to the screen that is quite small, but highly visible upon a background which is a real picture. Currently, I'm just using the text command to place text onto a real-life picture. Choosing the colours for the text on a picture that I know is relatively easy, so long as the picture doesn't contain any drastic contrast changes. What I want to do is be able to place any coloured text onto a picture chosen by the player that is easily visible and doesn't get lost in the backdrop.

The best way I can think to do this would be to have a semi-transparent grey area behind the text that would allow the user to faintly see the picture backdrop they are using. Come to think of it, this is seen in the Championship Manager games.

Sorry if this is a little confusing, I'll try and post of pics of what I've already achieved a bit later.

Hope someone has some advice?
John H
Retired Moderator
23
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 30th Mar 2003 22:22
Hmm you could try ghosting a sprite or a plane which would work for that little ghost effect.


RPGamer

Current - RPG: Eternal Destiny
http://www.halbrosproductions.netfirms.com
Dont ask those questions! Read the help files lazy! Oh ya, and Tat has a plugin for that!
Furiousuk
23
Years of Service
User Offline
Joined: 10th Jan 2003
Location: United Kingdom
Posted: 30th Mar 2003 23:13
I haven't got my own website so I can't post any pics of what I've already done.

Thanks for the reply RPGamer. I thought of doing it with a plane but I really want to keep this project in 2D, it'll just be a lot easier to code all of the screens, menus and buttons that way.
I think what I'll have to do is create a bitmap with enough black spaces to be considered semi-transparent and then set the transparency flag when using paste image.
Does anyone have an idea how to create the bitmap though?

There isn't some simple command I've over-looked that would solve this is there?
John H
Retired Moderator
23
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 31st Mar 2003 01:37
I think there is Get image and create bitmap?

RPGamer

Current - RPG: Eternal Destiny
http://www.halbrosproductions.netfirms.com
Dont ask those questions! Read the help files lazy! Oh ya, and Tat has a plugin for that!
Dave J
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Feb 2003
Location: Secret Military Pub, Down Under
Posted: 31st Mar 2003 03:42
Semi-Transparent is also known as Translucency.

"Computers are useless they can only give you answers."

Login to post a reply

Server time is: 2026-06-11 13:13:54
Your offset time is: 2026-06-11 13:13:54