Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /// KONSTRUKTOROK
- Vec3() {v[0]=0; v[1]=0; v[2]=0;} // Default konstruktor
- Vec3(T x, T y=0, T z=0) {v[0]=x; v[1]=y; v[2]=z;} // Init konstruktor
- Vec3(const Vec3& other) {v[0]=other.v[0]; v[1]=other.v[1]; v[2]=other.v[2];} // Copy konstruktor
- // Inicializálás tömbbel (vagy init list C++11 esetében)
- Vec3(const T arr[]) {v[0]=arr[0]; v[1]=arr[1]; v[2]=arr[2];}
- // Megjegyzés: memcpy(), memset() használata véleményem szerint itt annyira nem indokolt.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement