Let's assume that in a triangle we have computed the brightness on the vertices of a triangle and we have found that it is maximum.
Can any other point which lies on that triangle have more brightness than the maximum brightness on those vertices ?
Computer Graphics Stack Exchange is a question and answer site for computer graphics researchers and programmers. It only takes a minute to sign up.Sign up to join this community
That completely depends on how you are computing the shading. If you are then just linearly interpolating the shaded colours across the triangle, i.e. Gouraud shading then, clearly, the answer is "no".
However, if you are doing per-pixel shading by, say, interpolating normals and light directions, then you can easily get a brighter area away from the vertices.
Assuming you have almost any lighting model at all:
You cannot bound the view irradiance (light reflected from a surface location towards the eye/camera) by computing the irradiance at the vertices and bounding those, even if the surface is completely diffuse Lambertian and has no view-angle term.
Imagine a large floor triangle, and a point lighting near the center of the triangle, close to the surface. The center of the triangle is very bright, while the vertices - which are far away from the light source - are dark.
Alternatively, if you are just asking if a linearly interpolated quantity can exceed the value at any/all of the end points - then the answer is simply 'no' - your bounds are accurate. The key issue here is that irradiance is a non-linear function over the surface, but interpolation is linear
I am supplementing the answer of others by adding a picture showing a Blinn and Lambert material applied to a triangle (the triangle has normals in different directions at the corners to show the difference in shading). There is one distant directional light in the scene.
Image 1: Image shows lighting on a triangle lit by directional light.
By comparing the samples in image 1 we can see that the highest color value can be somewhere in the center of the triangle. Which shows that the assumption in your question is generally invalid.
So no you can not generally assume that the corners are the maximum of a triangle. A shader with this property can be constructed but quite a few shaders have this property naturally.