THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 02/01/2004 at 19:08, xxxxxxxx wrote:
Cinema 4D Version: 6.303
Platform: Windows ;
Language(s) : C.O.F.F.E.E ;
Is there a built in dot product function, I see that there is one for vcross() and vlen() but no vdot().
I am implementing an experimental lighting model, as such, I need the incident vector (denoted as I) from the camera position to the point currently being shaded. The vector I forms part of the formula in the lighting calculation.
If there is such a vector I, is there a way to find out the position of the current camera so that I can calculate the vector I myself?
On 03/01/2004 at 05:06, xxxxxxxx wrote:
No you need to calculate both yourself. You can get every camera except the Editor camera in COFFEE just like you get any other object too. Please refer to the SDK documentation.
On 09/01/2004 at 13:40, xxxxxxxx wrote:
For the record, vdot() isn't needed since the ordinary * product is the dot product for a pair of vectors.