Wow a sudden burst of activity on the forum.
I must have missed the discussion where the fresnel values for glass were decided. Oh well, I'm not THAT far off anyway. The material shader should be set to reflect=1 since the fresnel parameters just modulate to that value as a max value.
While we're on the subject, I would like some real lighting values for ambient/diffuse/specular
for a few materials. I've been reworking the lighting and have gotten rid of the glowing materials in shadow and some other odd behavior but I need some real values to tune the lighting engine to. I also found an error in the motion-blur calcs that appears to have fixed some strange problems we were having, wheels are still a problem with one of the schemes however. I've been looking at an algorithm that would work for wheels though. The other problem that's been making me crazy is getting rid of the specular in shadow for bump mapped materials such as tires, but I haven't given up.
The taillights...
The lighting changes...
Is anyone else getting tired of the pop-up about the tires! I wouldn't mind but you can't turn the stupid thing off.
The floating car problem shouldn't be impossible to fix either, all forces should logically work toward zero energy (except for y-axis) as motion decreases, OK camber would also give some static force but at 0 motion does it matter?
Alex Forbin
Hi Alex,
Hmmm, it's always busy around here, but usually it's tending to be off-topic weirdness where good discussion often happens.
I can't remember what thread we were talking about fresnel, but iirc it was me and Stereo and a few others at the time, specifically on his Simca, but not in the Simca thread
As per values, I've tended to just use real values from what people in arch-vis and the like are using.
In 3DS Max for instance many materials now run off real IOR, or use the same fresnel coefficients we do in Racer... they also tend to have properly balanced texture values (both gamma'd or linear), and just generally lots of good hard fast rules for what is realistic or isn't.
Ie, blackest black is probably near 0.02% rgb in linear space (which is what Racer uses in it's diffuse/ambient value inputs, only the texture itself is gamma'd or linearised)
That means a black swatch colour in PS for example, actually needs to be linearised to get the appropriate colour for Racer, IF you use a white swatch and then colourise with the amb/diff values.
If you don't do that, then you end up with colours that look too bright and washed out.
Obviously if you use a proper texture with colour in it, and run it in gamma space (ie, non-linear), then you don't need to worry about that.
I often think about wheels too for blurring, but it seems all the main developers still just use blur models for the best effect.
Thinking back to the Carrera GT that was made for Racer then they can look great... it's just taking the time to make all the shaders work right I guess.
I've found in many cases, setting the tyre motion blur to 0, but having the alloy blur, somehow contains the blur better. But ideally a proper wheel blur model is the best solution still. Unless of course someone can make a good blur shader that can do wheels nicely
As per tyres, mine work fine here in that regard.
I'm using this:
vf_bump_speca
{
vertex_shader
{
file=dyn_standard_bump_v.cg
}
fragment_shader
{
file=dyn_standard_bump_f.cg
}
}
shader_tyre~vf_bump_speca
{
cast_shadow=1
motion_blur=0
compression=0
specular=0.4 0.4 0.45
shininess=12
tangents=1
layer0
{
map=texture\tyre.tga
}
layer1
{
map=texture\tyre_norm.dds
mode=linear
mipmap_lod_bias=0
}
}
Obviously I'm using a bump map here too, but mine work fine... If you force all the car body shaders to cast_shadow=1 does it still show highlights in the shaded area?
Dave