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 / Shadows, but not Set Shadow Shading On, cos it sux:(

Author
Message
Cpt Caveman
23
Years of Service
User Offline
Joined: 29th Aug 2002
Location: New Zealand
Posted: 26th May 2003 12:52
For those of us with the 3d hardware that supports this, I personally have been very dissapointed with this command. It never works right with complex objects and is so slow if it does work and still gets corrupted. I've seen similar programs to DBpro do shadows successfull by faking it and I am pretty sure I saw a few screenshots/demos of programs written in DBpro/DB Classic that do a really fine shadow on the matrix. I know this question gets asked all the time, but why do I never see anyone helping out when shadows are concerned, please correct me if Im wrong!!
n3t3r453r
23
Years of Service
User Offline
Joined: 8th Nov 2002
Location: Russia
Posted: 26th May 2003 13:04 Edited at: 26th May 2003 17:04
Shadows, shadows ...

Try to position the second camera as a light. Shadow in that case will be what camera "see". Problem is to rotate this shadow from one plain (second camera) to another current camera. If you know English well enought then you can easily find needed(<-edit) information from internet. For example from developer.nvidia.com (or something like that)

I'd like to change the world, but God doesn't want to give me sources!
Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 26th May 2003 15:31
@Elemenop

Shadows are MASSIVELY complex things to render, so what I do, is to take a complex object, put a low poly version of that object, hidden, in the same place as the complex object and use the low poly object as the shadow caster. It looks good and there isn't too much slowdown. Faked shadows are generally done by texturing a plain with a silhouette of the object and lying it parallel with the ground.

Do you want Windows menus in your DBP apps? - Get my plugin: http://snow.prohosting.com/~clone99/downloads/tpc_menus_102.zip
ozak
23
Years of Service
User Offline
Joined: 22nd May 2003
Location: Denmark
Posted: 26th May 2003 17:03
Shadows are not working on my radeon 9000.
Needless to say, stencil shadows works like a charm on this card in both DirectX and OpenGL based games

Regards

Ozak

Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 26th May 2003 17:43
Are you sure that you are using them correctly?

Do you want Windows menus in your DBP apps? - Get my plugin: http://snow.prohosting.com/~clone99/downloads/tpc_menus_102.zip
David T
Retired Moderator
23
Years of Service
User Offline
Joined: 27th Aug 2002
Location: England
Posted: 26th May 2003 18:24
Same here. It worked really well in the basic3d showcase, but I could never get them working in my games.

You are the th person to view this signature.
Programmers don't die, they just Gosub without return....
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 26th May 2003 22:11
lol, funny because they have never worked for me in that basic3d showcase but i can get them going in my games :-s

Although in games i get really weird problems like if the camera moves into a shadow being cast by say a tree the shadow inverts and everywhere apart from where the shadow should be becomes shaded o.O

Is it possiable to do these stencil like shadows some other way? I compiled the basic3d showcase for a friend and it told him his card didnt support most of the things there, including shading. Yet take a look at say the quake 1 modification, tenebrae and the quake2 mod Evolved - they both use realistic stencil shadows and they all work on his card :/ Mind you, his card doesnt support dbp's bump mapping either.. and i know full well it works for him in like serious sam 2.. so something is being done weirdly *_*

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.
Rob K
Retired Moderator
23
Years of Service
User Offline
Joined: 10th Sep 2002
Location: Surrey, United Kingdom
Posted: 26th May 2003 22:20
"Although in games i get really weird problems like if the camera moves into a shadow being cast by say a tree the shadow inverts and everywhere apart from where the shadow should be becomes shaded o.O"

I am not sure if I understand the exact cause of this, but apparently there is something called "Carmack's Reverse" which has to be implemented to get around this. It is not really a bug, more a limitation of the way that DBP does shadows.

Do you want Windows menus in your DBP apps? - Get my plugin: http://snow.prohosting.com/~clone99/downloads/tpc_menus_102.zip
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th May 2003 22:20
ahh the dreaded curse of the Radeon strikes again mwhahaaa
personally i think stencil shadows look better than the DB Shader Shadows though ... oki perhaps if you have FSAA on, but still better

Within the Epic battle of the fates the Shadow and the Angel will meet. With it will harbinger the very fight of good vs evil!
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 26th May 2003 22:26
"I am not sure if I understand the exact cause of this, but apparently there is something called "Carmack's Reverse" which has to be implemented to get around this."

I may look into that ^^ but im not sure though.. shadow shading seems very slow (granted, its very intensive) and doesnt seem to even work on a good portion of pcs -_-

"ahh the dreaded curse of the Radeon strikes again mwhahaaa
personally i think stencil shadows look better than the DB Shader Shadows though ... oki perhaps if you have FSAA on, but still better"

lol - i have a geforce4 mx 440 ;
Stencil shading sounds intresting. i think im going to whack it into google and see what i get

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 26th May 2003 22:32
hmm, i may be way off the mark, but stencil shading appears to be an openGL only deal -_- Judging from what i have read so far anyway :/

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 26th May 2003 23:35
you can run the Shadow Shader on your GF4... interesting, i thought it was done differently.

Stencil is also a buffer effect in DirectX 8.0 in the D3Dx

Within the Epic battle of the fates the Shadow and the Angel will meet. With it will harbinger the very fight of good vs evil!
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 26th May 2003 23:46
hmm yes - whats even more intresting is that i didnt expect my gf4 (being an mx440) to support much - but the basic3d showcase claims that i can support *everything* there! However, only cube mapping and rainbow shading seem to be working correctly there. But i really dont know what to belive.. it tells me i support everything.. only 2 things work.. but shadow shaders dont work there yet do in a seperate game im writing.. go figure!

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 26th May 2003 23:47
oh btw, raven, a quick question (i hope you dont mind ^_^)

i saw screen shots of that mgs thingy (im damn sure it was you who was working on it, man will i look stupid if it wasnt XD) - i saw the nice shadows there, was that the dbp native shadow commands in action or a seperate, home-made, system?

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.
Shadow Robert
23
Years of Service
User Offline
Joined: 22nd Sep 2002
Location: Hertfordshire, England
Posted: 27th May 2003 00:49
lol... i think you've just made yourself look stupid
i was making models for it, nothing more - the game in the state it goto is all FurEffects work, so i'd ask him (once his exams are over and done with and he's back)

Within the Epic battle of the fates the Shadow and the Angel will meet. With it will harbinger the very fight of good vs evil!
Sephnroth
23
Years of Service
User Offline
Joined: 10th Oct 2002
Location: United Kingdom
Posted: 27th May 2003 01:07
ahh.. well i was nearly there! i guess that makes me 50% moron

p4 2.4ghz, 256ddr ram, Geforce4 MX 440
Innovate, redefine, recreate whats in your mind. It isnt fate, you decide, only you can cross that line.

Login to post a reply

Server time is: 2026-07-11 22:25:22
Your offset time is: 2026-07-11 22:25:22