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 Professional Discussion / How does bump map works in DBpro

Author
Message
Bulleyes
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: Cyberjaya, Malaysia
Posted: 1st Apr 2003 16:12
What kind of image should I specified as the bump map in the SET BUMP MAPPING ON command. Initially, I thought the bump map suppose to be a greyscale image with the gray value of each pixels as the depth of the surface bumps.

But when I look at the bump mapping demo came with DBpro, it seems that the the bump map are true color. I am confused now. What does the RGB values of each pixel means in the bump map?

Any help will be greatly appreciated!
Bad Nose Entertainment - Where games are forged from the flames of talent and passion.

http://www.badnose.com/
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 1st Apr 2003 16:25
don't worry bump mapping works by taking the Lumination of the pixels rather than the actual colour
oftenly you will use a greyscale image - however sometimes its better to use all 4billion colour using curve values to setup the depth better when you invert the bitmaps they generally get a blue-ish or pink-ish hue.

it could be confusing at first but isn't anything particularly new

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?
Bulleyes
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: Cyberjaya, Malaysia
Posted: 1st Apr 2003 16:44
Thanks Raven. You are always my life saver!

But how do I design a bump map. It seems very obvious and straighforward to me if a greyscale bump map is used. But now with the true color bump map, I am confused how to interprete each pixel in the bump map.

Bad Nose Entertainment - Where games are forged from the flames of talent and passion.

http://www.badnose.com/
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 1st Apr 2003 17:24
well its just DBS being lazy to set it up really, just make the bump map how you would before ... alternatively there is a plugin you can get for photoshop called 'Normal Mapper' and it does this automatically - but really nothing you can't do yourself with a few mins on ya hands.

Grab the image you want to make a bump map, and invert it's colour (can even do this in MS Paint) ... and well thats about it really, you'll have all the information the bump mapping utility needs.
But if you want to actually be fancy just work a picture's current features you want to bump - and then do the same thing, i mean the colours mean nothing... you're still blending on the Lumination or Combined Greyscale Brightness of each pixel (this was set about to allow hardware to precalculate Bump Maps on the already present texture, or something like that)

try not to let it to confuse you, same beastie, just different look
kinda like a girl and her hair colour really

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?
Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 1st Apr 2003 17:52
Greyscale images work fine for me - If you want to create one just use any paint program that allows you to adjust the colour saturation of the image and set it to zero.

BUMP MAPPING is probably another half-assed feature (like Shadow shading, reflection shading etc.) .. but you never know.

Current Project: Retro Compo. Entry.
Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 1st Apr 2003 17:53
Also, if you use Paint Shop Pro, and probably photoshop you can set it to display the luminance of the pixel which the mouse is currently over.

Current Project: Retro Compo. Entry.
Bulleyes
23
Years of Service
User Offline
Joined: 3rd Nov 2002
Location: Cyberjaya, Malaysia
Posted: 1st Apr 2003 17:56
Hmmm... sorry... i am a little bit slow. Well, maybe I should put it another way.

I run the bump mapping demo in DBpro. Then I tried to change its true color bump map into a greyscaled ones. It seems like the greyscale bump map makes the model darker than the color one.

How do you explain this? I am quite a slow learner eh.

Bad Nose Entertainment - Where games are forged from the flames of talent and passion.

http://www.badnose.com/
Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 1st Apr 2003 23:08
DBP doesn't use normal DOT3 bump mapping - I know that for a fact, I think it uses shaders or some other method to do it.

Current Project: Retro Compo. Entry.
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 2nd Apr 2003 00:36
it probably is pixel shader or something because there is a single command

dp3_sat r0, t0_bx2, v0_bx2

which will use a dot3 saturation using register 0, texture 0 w/3x3 matrix, light 0 w/3x3 matrix
i've not had a chance to see the effect at work unfortunatly to know for sure ... it is much better for more cards if perhaps you used standard bump mapping, which is nice and simple.

http://users.ox.ac.uk/~univ1234/tutorials/simplebump/simplebump.htm
http://www.sgi.com/software/opengl/advanced98/notes/node107.html

you may find both of these links very useful as they describe the steps quite well

Tsu'va Oni Ni Jyuuko Fiori Sei Tau!
One block follows the suit ... the whole suit of blocks is the path ... what have you found?

Login to post a reply

Server time is: 2026-07-21 20:34:28
Your offset time is: 2026-07-21 20:34:28