Jump to content

  • Log In with Google      Sign In   
  • Create Account

Awesome job so far everyone! Please give us your feedback on how our article efforts are going. We still need more finished articles for our May contest theme: Remake the Classics

#ActualAshaman73

Posted 10 October 2012 - 04:03 AM

First off, your glsl haa no line breaks making it incredible hard to read.

Then your left texture, what is it ? The diffuse map, in this case it would contain pseodo light information which will result in a weird look at the edges.

For the usual lighting methods, do you multiply by a distance factor?

Yes, it is even sometimes useful to not only reduce the intensity with distance but to clamp it to a certain area (ie. sphere). A simple,smooth clamping function would be

normalized_distance = min(1.0, dist / max_dist);
final_intensity = (1.0 - normalized_distance * normalized_distance) * intensity;


I'm told the Phong Reflection Model may be better suited in this case.

Better suited compared to what ?
You should choose a diffuse model (ie lambert) and a specular model (ie phong or blinn).


Here you can see the diffuse lightingmodel demonstrated in blender and here the specular models. Lambert,phong,blinn are the easiest one, the others are more complicated.

#4Ashaman73

Posted 10 October 2012 - 04:00 AM

First off, your glsl haa no line breaks making it incredible hard to read.

Then your left texture, what is it ? The diffuse map, in this case it would contain pseodo light information which will result in a weird look at the edges.

For the usual lighting methods, do you multiply by a distance factor?

Yes, it is even sometimes useful to not only reduce the intensity with distance but to clamp it to a certain area (ie. sphere). A simple,smooth clamping function would be

normalized_distance = min(1.0, dist / max_dist);
final_intensity = (1.0 - normalized_distance * normalized_distance) * intensity;


I'm told the Phong Reflection Model may be better suited in this case.

Better suited compared to what ?
You should choose a diffuse model (ie lambert) and a specular model (ie phong or blinn).

#3Ashaman73

Posted 10 October 2012 - 03:59 AM

First off, your glsl haa no line breaks making it incredible hard to read.

Then your left texture, what is it ? The diffuse map, in this case it would contain pseodo light information which will result in a weird look at the edges.

For the usual lighting methods, do you multiply by a distance factor?

Yes, it is even sometimes useful to not only reduce the intensity with distance but to clamp it to a certain area (ie. sphere). A simple,smooth clamping function would be

normalized_distance = min(1.0, dist / max_dist);
final_intensity = (1.0 - normalized_distance * normalized_distance) * intensity;


I'm told the Phong Reflection Model may be better suited in this case.

Better suited compared to what ?
You should choose a diffuse model (ie lamber) and a specular model (ie phong or blinn).

#2Ashaman73

Posted 10 October 2012 - 03:58 AM

First off, your glsl haa no line breaks making it incredible hard to read.

Then your left texture, what is it ? The diffuse map, in this case it would contain pseodo light information which will result in a weird look, best to test the lighting.

For the usual lighting methods, do you multiply by a distance factor?

Yes, it is even sometimes useful to not only reduce the intensity with distance but to clamp it to a certain area (ie. sphere). A simple,smooth clamping function would be

normalized_distance = min(1.0, dist / max_dist);
final_intensity = (1.0 - normalized_distance * normalized_distance) * intensity;


I'm told the Phong Reflection Model may be better suited in this case.

Better suited compared to what ?
You should choose a diffuse model (ie lamber) and a specular model (ie phong or blinn).

#1Ashaman73

Posted 10 October 2012 - 03:58 AM

First off, your glsl have no line breaks making it incredible hard to read.

Then your left texture, what is it ? The diffuse map, in this case it would contain pseodo light information which will result in a weird look, best to test the lighting.

For the usual lighting methods, do you multiply by a distance factor?

Yes, it is even sometimes useful to not only reduce the intensity with distance but to clamp it to a certain area (ie. sphere). A simple,smooth clamping function would be

normalized_distance = min(1.0, dist / max_dist);
final_intensity = (1.0 - normalized_distance * normalized_distance) * intensity;


I'm told the Phong Reflection Model may be better suited in this case.

Better suited compared to what ?
You should choose a diffuse model (ie lamber) and a specular model (ie phong or blinn).

PARTNERS