|
|
Quake3 engine "reflectivity"
#55910
09/23/05 07:26
09/23/05 07:26
|
Joined: Dec 2003
Posts: 1,220 Just down the road from Raven
BlueBeast
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,220
Just down the road from Raven
|
Hope this is the proper thread to ask...
The mirror effect I'd like to recreate, is the one where surfaces appear to be semi reflective, you can see it best when moving by them. Though it makes for a generic mirror, it looks great on what would be stainless steel appliances in large kitchens. Half life and Soldier of Fortune 2 used this effect too in a lot of cases. (Water puddles, metals, glass etc etc)
Im guessing it's used on models. What kind of code am i looking for to implement this effect? What's the lowest shader version it can use?
Any and all help greatly appreciated!
Thanks!
Jason
Gamestudio Pro 6.4 Pentium 4 3.0 GHz 800MHz BUS AtiRadeon 9800 pro 256Mb 21" Monitor 1 Gig DDR RAM 36 Gig RAPTOR SATA+ 120 Gig SATA SB Audigy 2 w/ 450 watt Logitech Z680 5.1 www.nordicepitaph.com
|
|
|
Re: Quake3 engine "reflectivity"
[Re: Sebe]
#55913
09/23/05 18:27
09/23/05 18:27
|
Joined: Dec 2003
Posts: 1,220 Just down the road from Raven
BlueBeast
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,220
Just down the road from Raven
|
I havnt tested it yet, but I'm almost positive that's the one! Thanks bunches!
BTW Is there any particular shader specification needed for this? Like PS 1.0 etc etc? or any other specs for that matter?
Jason
Gamestudio Pro 6.4 Pentium 4 3.0 GHz 800MHz BUS AtiRadeon 9800 pro 256Mb 21" Monitor 1 Gig DDR RAM 36 Gig RAPTOR SATA+ 120 Gig SATA SB Audigy 2 w/ 450 watt Logitech Z680 5.1 www.nordicepitaph.com
|
|
|
Re: Quake3 engine "reflectivity"
[Re: Sebe]
#55915
10/08/05 19:26
10/08/05 19:26
|
Joined: Dec 2003
Posts: 1,220 Just down the road from Raven
BlueBeast
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,220
Just down the road from Raven
|
i'm unfortunatly getting errors.... I have the 'include' added to the level (enviromaptest.wdl) and the action 'envmap' is there and assigned to a model. This is the envmap.wdl : ----------------------------------------------------------------------- Code:
bmap bcube=<cube+6.tga>;
function mtl_envmap_view() { mat_set(mtl.matrix,matViewInv); mtl.matrix41=0; mtl.matrix42=0; mtl.matrix43=0; }
function mtl_envmap_init() { //...maybe you should copy the mat_model properties here... bmap_to_cubemap(mtl.skin1); mtl.event=mtl_envmap_view; mtl.enable_view=on; }
material mtl_envmap { skin1=bcube; event=mtl_envmap_init;
effect= " texture entSkin1; texture mtlSkin1; matrix matMtl; technique envmap { pass p0 { texture[0]=<entSkin1>; texture[1]=<mtlSkin1>;
zWriteEnable=true; alphaBlendEnable=false;
colorArg1[0]=Texture; colorOp[0]=Modulate2x; colorArg2[0]=Diffuse;
colorArg1[1]=Texture; colorOp[1]=blendCurrentAlpha; addressU[1]=Clamp; addressV[1]=Clamp; texCoordIndex[1]=cameraSpaceReflectionVector; textureTransformFlags[1]=Count3; textureTransform[1]=<matMtl>; // transform camera space back to world space } } "; }
Action envmap //or whatever you want to call it { My.material = mtl_envmap; //Whatever else you want the model to do goes here… } ---------------------------------------------------------------------------------------------------------------------------------------------------------------- Please help THANKS! Jason
Gamestudio Pro 6.4 Pentium 4 3.0 GHz 800MHz BUS AtiRadeon 9800 pro 256Mb 21" Monitor 1 Gig DDR RAM 36 Gig RAPTOR SATA+ 120 Gig SATA SB Audigy 2 w/ 450 watt Logitech Z680 5.1 www.nordicepitaph.com
|
|
|
Re: Quake3 engine "reflectivity"
[Re: Lion_Ts]
#55918
10/09/05 07:07
10/09/05 07:07
|
Joined: Dec 2003
Posts: 1,220 Just down the road from Raven
BlueBeast
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,220
Just down the road from Raven
|
I have Pro 6.31.4, And DX 90c The errors speak for themselves... Unknown this, unknown that, and the empty action... something in there must be wrong...
EDIT: I recently got Pro, so im changing the Comm in my profile.. but i just noticed i still only have 6.11.4 i'll update and then try it...
Aaaand IT WORKS! It's always the little things isn't it? Thanks for the tip about updating!
Jason
Gamestudio Pro 6.4 Pentium 4 3.0 GHz 800MHz BUS AtiRadeon 9800 pro 256Mb 21" Monitor 1 Gig DDR RAM 36 Gig RAPTOR SATA+ 120 Gig SATA SB Audigy 2 w/ 450 watt Logitech Z680 5.1 www.nordicepitaph.com
|
|
|
Re: Quake3 engine "reflectivity"
[Re: Sebe]
#55919
10/11/05 18:38
10/11/05 18:38
|
Joined: Sep 2003
Posts: 648 Switzerland
snake67
User
|
User
Joined: Sep 2003
Posts: 648
Switzerland
|
Hey, great tut so far. I made a "reflexion"-effect aout of it. What i am still searching for, is a similar effect, but suitable for glass surfaces (like seen in NOLF f.e.). I think the effect should shift, when the camera passes by...
Any idea?
And.. yes, i only own a old graphics card: GeForce Ti4200...
Last edited by snake67; 10/11/05 18:40.
|
|
|
|