91 #ifndef PROTOTYPEVEC4D_HH 92 #define PROTOTYPEVEC4D_HH 95 #include <QtCore/QObject> 96 #include <QtScript/QtScript> 117 void multiply(QScriptValue _scalar);
123 void add(QScriptValue _vector);
129 void sub(QScriptValue _vector);
142 QScriptValue
sprod(QScriptValue _vector);
162 QString toString()
const;
167 #endif // PROTOTYPEVEC4D_HH QScriptValue norm()
Calculate the Euclidean norm of the vector.
void sub(QScriptValue _vector)
Subtracts another vector from this vector.
QScriptValue sqrnorm()
Calculate the squared Euclidean norm of the vector.
void multiply(QScriptValue _scalar)
Multiplies the given vector with the scalar.
QScriptValue sprod(QScriptValue _vector)
Calculate scalar product.
void add(QScriptValue _vector)
Adds another vector to this vector.
void zero()
Resets all components of the vector to zero.
void normalize()
Normalize the vector.