Game Development Community

Further shader questions

by Mark Pilkington · in Game Design and Creative Issues · 10/22/2006 (2:03 am) · 5 replies

I really have tried figuring this out.

I want my floor to be slightly reflective and shiny. I've looked at the TSE doc and tried both the examples fort creating a simple reflective plane but I can't seem to get this to work.

The top example:
new Material(tiles1)
	{
		texture[1] = "$backbuff";
		baseTex[0] = "tiles1_d";
		bumpTex[2] = "tiles1_local";
		shader = ReflectBump;
		version = 2.0;
		planarReflection = true;
	};

Turns my floor black and the game runs really slow so I feel that is almost working while the second example I tried:

new Material(tiles1_reflect)
	{
    texture[0] = "tiles1_d";
    texture[1] = "$backbuff";
    shader = Reflect;
    version = 1.4;
    planarReflection = true;
	};

Doesn't seem to work at all and applies the orange 'no material' on it.

Any ideas is much appreciated here and it would just complete the scene.

Cheers

#1
10/25/2006 (1:39 am)
Also I have another problem involving glass.

blacktreeuk.net/misc/glass1.jpg
blacktreeuk.net/misc/glass2.jpg
The first image is my glass shader that looks like its working fine.

The second image is the same glass shader, the light inside the room seems to be doing some really weird stuff to the glass and its just not very glass like there. I have no idea whats going on really or how to fix it.

new Material(glass)
	{
		baseTex[0] = "glass1_d";
		cubemap = lobby;
		
		translucent = true;
		translucentBlendOp = sub;
		
		pixelSpecular[0] = false;
	};

This is my shader for the glass texture. I also want to eventaully make glass that has a solid shatter proof wire and other kind of glass textures. I have messed about with it but it seems to invert the colours of the wire, This probably has something to do with my blendOp but no other blend Op apartfrom Sub works otherwise the glass turns black.

Any help in shaders is appreciated as it seems to be an uncovered area.
#2
10/30/2006 (1:22 am)
Also what is the parm for drawing textures two-sided?
#3
01/16/2008 (8:34 am)
It looks like you are really doing a good job overall. I am working on the shader portion today and this week. I will compare notes with you when I find out anything; assuming you are even working with anymore. I am replying because I see that no one replied to your post for some reason... it happens sometimes. It appears the shader portion has got a lot of people frustrated to the point of concentrating on other issues instead. Otherwise I can't explain why this forum is dead here.

Take Care
#4
01/16/2008 (8:51 am)
The post is too old "Posted: Oct 30, 2006 11:22" ... don't wait for response IMO.
#5
09/13/2008 (8:37 am)
But it seems relevant enough... ;-)