1 registered members (flink),
767
guests, and 5
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Environment mapping can not display on Geforce MX.
[Re: maxxoros]
#48054
06/18/05 16:18
06/18/05 16:18
|
Joined: Nov 2003
Posts: 1,267 ef
Christoph_B
Serious User
|
Serious User
Joined: Nov 2003
Posts: 1,267
ef
|
even if it's basic, it's a shader and the 440 mx is just a bit newer version of the geforce 2, that doesn't support shaders yet.
sef
|
|
|
Re: Environment mapping can not display on Geforce
[Re: Pappenheimer]
#48059
06/20/05 04:03
06/20/05 04:03
|
Joined: Jun 2005
Posts: 59
maxxoros
OP
Junior Member
|
OP
Junior Member
Joined: Jun 2005
Posts: 59
|
To Pappenheimer: Is this thread you mentioned http://www.coniserver.net/ubbthreads/sho...part=2&vc=1In this thread, steempipe give code for none pixel-shader-user, but he still use vertex shader and geforce MX 440 does not support this -------- Can anyone tell me where to get this code...because to XeXeS, he still use env map only with Geforce 2 ---- Thanks for your help
|
|
|
Re: Environment mapping can not display on Geforce
[Re: maxxoros]
#48060
06/20/05 05:36
06/20/05 05:36
|
Joined: Oct 2001
Posts: 1,163 Germany
XeXeS
Serious User
|
Serious User
Joined: Oct 2001
Posts: 1,163
Germany
|
Here is the code for Environmentmapping with the Fixed Function Pipeline: Code:
// Environmentmap bmap EnvMap = <EnvMap+6.tga> // Bitmap with the environment Map
// Material material matFFPEnvMapping { // Skin zuweisen skin1 = EnvMap; // Effectcode effect = " // Textures texture mtlSkin1; // Technique technique EnvMapping01 { pass pass01 { // Setup textures Texture[0] = <mtlSkin1>; // Setup Texture Addressing AddressU[0] = Clamp; AddressV[0] = Clamp; // Setup Textureblending ColorArg1[0] = Texture; ColorOp[0] = SelectArg1; // How to use Texture coordinates TexCoordIndex[0] = CameraSpaceReflectionVector; TextureTransformFlags[0] = Count3; } } technique fallback { pass p0 { } } "; }
// Material material matFFPEnvMappingWS { // Skin zuweisen skin1 = EnvMap; // Effectcode effect = " // Textures texture mtlSkin1; texture entSkin1; // Technique technique EnvMapping01 { pass pass01 { // Setup textures Texture[0] = <mtlSkin1>; Texture[1] = <entSkin1>; // Setup Texture Addressing AddressU[0] = Clamp; AddressV[0] = Clamp; // Setup Textureblending ColorArg1[0] = Texture; ColorOp[0] = SelectArg1; ColorOp[1] = Modulate; ColorArg1[1] = Current; ColorArg2[1] = Texture; // How to use Texture coordinates TexCoordIndex[0] = CameraSpaceReflectionVector; TextureTransformFlags[0] = Count3; } } technique fallback { pass p0 { } } "; }
starter ConvertEnvMapToCubeMap { bmap_to_cubemap(matFFPEnvMapping.skin1); }
starter ConvertEnvMapToCubeMapWS { bmap_to_cubemap(matFFPEnvMappingWS.skin1); }
I've posted two materials: The first one only uses the Environmentmap as Texture. The second one uses the Environmentmap and the Entityskin as Texture ( Multitexturing ) so you can see both on the entity. Have fun XeXeS
Last edited by XeXeS; 06/20/05 06:10.
|
|
|
Re: Environment mapping can not display on Geforce
[Re: XeXeS]
#48061
06/20/05 06:41
06/20/05 06:41
|
Joined: Oct 2001
Posts: 1,163 Germany
XeXeS
Serious User
|
Serious User
Joined: Oct 2001
Posts: 1,163
Germany
|
Hello, I have changed the code so you can adjust the value of the Reflection in Skill1 of the matieral: Code:
material matFFPEnvMappingWS {
// Skin zuweisen skin1 = EnvMap;
// Effectcode effect = " // Textures texture mtlSkin1; texture entSkin1; // Variables DWORD mtlSkill1; // Technique technique EnvMapping01 { pass pass01 { // Setup textures Texture[0] = <mtlSkin1>; Texture[1] = <entSkin1>;
// Setup Texture Addressing AddressU[0] = Clamp; AddressV[0] = Clamp; TextureFactor = <mtlSkill1>; // Setup Textureblending ColorArg1[0] = Texture; ColorOp[0] = Modulate; ColorArg2[0] = TFactor; ColorOp[1] = Add; ColorArg1[1] = Current; ColorArg2[1] = Texture;
// How to use Texture coordinates TexCoordIndex[0] = CameraSpaceReflectionVector; TextureTransformFlags[0] = Count3; } }
technique fallback { pass p0 { } } "; }
starter ConvertEnvMapToCubeMapWS { bmap_to_cubemap(matFFPEnvMappingWS.skin1); matFFPEnvMappingWS.skill1 = pixel_for_vec(vector(30,30,30),100,8888); }
I've not tested this code at all so I not gurantee that it works fine. Or that there are no errors.
Last edited by XeXeS; 06/20/05 07:15.
|
|
|
Re: Environment mapping can not display on Geforce
[Re: XeXeS]
#48062
06/20/05 22:09
06/20/05 22:09
|
Joined: Sep 2002
Posts: 8,177 Netherlands
PHeMoX
Senior Expert
|
Senior Expert
Joined: Sep 2002
Posts: 8,177
Netherlands
|
Heaps of thanks XeXes!! I will try these codes as soon as possible... I was just wondering, I've downloaded the Aquamark 3 benchmark program some days ago, and they got this really cool 'masked environmental (reflection) mapping' on their model. This makes the submarine have a really nice metal/shiny look, but not the 'overdone' environmental mapping, which often produces a grey/silver/pink effect. Anyway, first thing tomorrow, I'm gonna test your codes ! Edit: couldnt resist trying it out already! Works perfect and exactly the effect like in Aquamark3 !!! YEAHH!!! Thanks man! Oww you forgot a ; at the end of bmap EnvMap = <EnvMap+6.tga> // Bitmap with the environment Map ... Cheers
Last edited by PHeMoX; 06/20/05 22:20.
|
|
|
|