PolyhedronGeometryVertex class
PolyhedronGeometryVertex is a Vector3 decorator to allow introducing index and uv.
class PolyhedronGeometryVertex extends Vector3 { int index; UV uv; PolyhedronGeometryVertex([num x = 0.0, num y = 0.0, num z = 0.0]) : super(x.toDouble(), y.toDouble(), z.toDouble()); PolyhedronGeometryVertex.fromVector3(Vector3 other) : super.copy(other); }
Extends
Vector3 > PolyhedronGeometryVertex
Constructors
Properties
double b #
double get b => storage[2];
set b(double arg) => storage[2] = arg;
final Vector3 bbb #
Vector3 get bbb => new Vector3(storage[2], storage[2], storage[2]);
final Vector4 bbbb #
Vector4 get bbbb => new Vector4(storage[2], storage[2], storage[2], storage[2]);
final Vector4 bbbg #
Vector4 get bbbg => new Vector4(storage[2], storage[2], storage[2], storage[1]);
final Vector4 bbbr #
Vector4 get bbbr => new Vector4(storage[2], storage[2], storage[2], storage[0]);
final Vector3 bbg #
Vector3 get bbg => new Vector3(storage[2], storage[2], storage[1]);
final Vector4 bbgb #
Vector4 get bbgb => new Vector4(storage[2], storage[2], storage[1], storage[2]);
final Vector4 bbgg #
Vector4 get bbgg => new Vector4(storage[2], storage[2], storage[1], storage[1]);
final Vector4 bbgr #
Vector4 get bbgr => new Vector4(storage[2], storage[2], storage[1], storage[0]);
final Vector3 bbr #
Vector3 get bbr => new Vector3(storage[2], storage[2], storage[0]);
final Vector4 bbrb #
Vector4 get bbrb => new Vector4(storage[2], storage[2], storage[0], storage[2]);
final Vector4 bbrg #
Vector4 get bbrg => new Vector4(storage[2], storage[2], storage[0], storage[1]);
final Vector4 bbrr #
Vector4 get bbrr => new Vector4(storage[2], storage[2], storage[0], storage[0]);
Vector2 bg #
Vector2 get bg => new Vector2(storage[2], storage[1]);
set bg(Vector2 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; }
final Vector3 bgb #
Vector3 get bgb => new Vector3(storage[2], storage[1], storage[2]);
final Vector4 bgbb #
Vector4 get bgbb => new Vector4(storage[2], storage[1], storage[2], storage[2]);
final Vector4 bgbg #
Vector4 get bgbg => new Vector4(storage[2], storage[1], storage[2], storage[1]);
final Vector4 bgbr #
Vector4 get bgbr => new Vector4(storage[2], storage[1], storage[2], storage[0]);
final Vector3 bgg #
Vector3 get bgg => new Vector3(storage[2], storage[1], storage[1]);
final Vector4 bggb #
Vector4 get bggb => new Vector4(storage[2], storage[1], storage[1], storage[2]);
final Vector4 bggg #
Vector4 get bggg => new Vector4(storage[2], storage[1], storage[1], storage[1]);
final Vector4 bggr #
Vector4 get bggr => new Vector4(storage[2], storage[1], storage[1], storage[0]);
Vector3 bgr #
Vector3 get bgr => new Vector3(storage[2], storage[1], storage[0]);
set bgr(Vector3 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 bgrb #
Vector4 get bgrb => new Vector4(storage[2], storage[1], storage[0], storage[2]);
final Vector4 bgrg #
Vector4 get bgrg => new Vector4(storage[2], storage[1], storage[0], storage[1]);
final Vector4 bgrr #
Vector4 get bgrr => new Vector4(storage[2], storage[1], storage[0], storage[0]);
Vector2 br #
Vector2 get br => new Vector2(storage[2], storage[0]);
set br(Vector2 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; }
final Vector3 brb #
Vector3 get brb => new Vector3(storage[2], storage[0], storage[2]);
final Vector4 brbb #
Vector4 get brbb => new Vector4(storage[2], storage[0], storage[2], storage[2]);
final Vector4 brbg #
Vector4 get brbg => new Vector4(storage[2], storage[0], storage[2], storage[1]);
final Vector4 brbr #
Vector4 get brbr => new Vector4(storage[2], storage[0], storage[2], storage[0]);
Vector3 brg #
Vector3 get brg => new Vector3(storage[2], storage[0], storage[1]);
set brg(Vector3 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 brgb #
Vector4 get brgb => new Vector4(storage[2], storage[0], storage[1], storage[2]);
final Vector4 brgg #
Vector4 get brgg => new Vector4(storage[2], storage[0], storage[1], storage[1]);
final Vector4 brgr #
Vector4 get brgr => new Vector4(storage[2], storage[0], storage[1], storage[0]);
final Vector3 brr #
Vector3 get brr => new Vector3(storage[2], storage[0], storage[0]);
final Vector4 brrb #
Vector4 get brrb => new Vector4(storage[2], storage[0], storage[0], storage[2]);
final Vector4 brrg #
Vector4 get brrg => new Vector4(storage[2], storage[0], storage[0], storage[1]);
final Vector4 brrr #
Vector4 get brrr => new Vector4(storage[2], storage[0], storage[0], storage[0]);
double g #
double get g => storage[1];
set g(double arg) => storage[1] = arg;
Vector2 gb #
Vector2 get gb => new Vector2(storage[1], storage[2]);
set gb(Vector2 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; }
final Vector3 gbb #
Vector3 get gbb => new Vector3(storage[1], storage[2], storage[2]);
final Vector4 gbbb #
Vector4 get gbbb => new Vector4(storage[1], storage[2], storage[2], storage[2]);
final Vector4 gbbg #
Vector4 get gbbg => new Vector4(storage[1], storage[2], storage[2], storage[1]);
final Vector4 gbbr #
Vector4 get gbbr => new Vector4(storage[1], storage[2], storage[2], storage[0]);
final Vector3 gbg #
Vector3 get gbg => new Vector3(storage[1], storage[2], storage[1]);
final Vector4 gbgb #
Vector4 get gbgb => new Vector4(storage[1], storage[2], storage[1], storage[2]);
final Vector4 gbgg #
Vector4 get gbgg => new Vector4(storage[1], storage[2], storage[1], storage[1]);
final Vector4 gbgr #
Vector4 get gbgr => new Vector4(storage[1], storage[2], storage[1], storage[0]);
Vector3 gbr #
Vector3 get gbr => new Vector3(storage[1], storage[2], storage[0]);
set gbr(Vector3 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 gbrb #
Vector4 get gbrb => new Vector4(storage[1], storage[2], storage[0], storage[2]);
final Vector4 gbrg #
Vector4 get gbrg => new Vector4(storage[1], storage[2], storage[0], storage[1]);
final Vector4 gbrr #
Vector4 get gbrr => new Vector4(storage[1], storage[2], storage[0], storage[0]);
final Vector3 ggb #
Vector3 get ggb => new Vector3(storage[1], storage[1], storage[2]);
final Vector4 ggbb #
Vector4 get ggbb => new Vector4(storage[1], storage[1], storage[2], storage[2]);
final Vector4 ggbg #
Vector4 get ggbg => new Vector4(storage[1], storage[1], storage[2], storage[1]);
final Vector4 ggbr #
Vector4 get ggbr => new Vector4(storage[1], storage[1], storage[2], storage[0]);
final Vector3 ggg #
Vector3 get ggg => new Vector3(storage[1], storage[1], storage[1]);
final Vector4 gggb #
Vector4 get gggb => new Vector4(storage[1], storage[1], storage[1], storage[2]);
final Vector4 gggg #
Vector4 get gggg => new Vector4(storage[1], storage[1], storage[1], storage[1]);
final Vector4 gggr #
Vector4 get gggr => new Vector4(storage[1], storage[1], storage[1], storage[0]);
final Vector3 ggr #
Vector3 get ggr => new Vector3(storage[1], storage[1], storage[0]);
final Vector4 ggrb #
Vector4 get ggrb => new Vector4(storage[1], storage[1], storage[0], storage[2]);
final Vector4 ggrg #
Vector4 get ggrg => new Vector4(storage[1], storage[1], storage[0], storage[1]);
final Vector4 ggrr #
Vector4 get ggrr => new Vector4(storage[1], storage[1], storage[0], storage[0]);
Vector2 gr #
Vector2 get gr => new Vector2(storage[1], storage[0]);
set gr(Vector2 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; }
Vector3 grb #
Vector3 get grb => new Vector3(storage[1], storage[0], storage[2]);
set grb(Vector3 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 grbb #
Vector4 get grbb => new Vector4(storage[1], storage[0], storage[2], storage[2]);
final Vector4 grbg #
Vector4 get grbg => new Vector4(storage[1], storage[0], storage[2], storage[1]);
final Vector4 grbr #
Vector4 get grbr => new Vector4(storage[1], storage[0], storage[2], storage[0]);
final Vector3 grg #
Vector3 get grg => new Vector3(storage[1], storage[0], storage[1]);
final Vector4 grgb #
Vector4 get grgb => new Vector4(storage[1], storage[0], storage[1], storage[2]);
final Vector4 grgg #
Vector4 get grgg => new Vector4(storage[1], storage[0], storage[1], storage[1]);
final Vector4 grgr #
Vector4 get grgr => new Vector4(storage[1], storage[0], storage[1], storage[0]);
final Vector3 grr #
Vector3 get grr => new Vector3(storage[1], storage[0], storage[0]);
final Vector4 grrb #
Vector4 get grrb => new Vector4(storage[1], storage[0], storage[0], storage[2]);
final Vector4 grrg #
Vector4 get grrg => new Vector4(storage[1], storage[0], storage[0], storage[1]);
final Vector4 grrr #
Vector4 get grrr => new Vector4(storage[1], storage[0], storage[0], storage[0]);
final bool isInfinite #
True if any component is infinite.
bool get isInfinite { bool is_infinite = false; is_infinite = is_infinite || storage[0].isInfinite; is_infinite = is_infinite || storage[1].isInfinite; is_infinite = is_infinite || storage[2].isInfinite; return is_infinite; }
final bool isNaN #
True if any component is NaN.
bool get isNaN { bool is_nan = false; is_nan = is_nan || storage[0].isNaN; is_nan = is_nan || storage[1].isNaN; is_nan = is_nan || storage[2].isNaN; return is_nan; }
final double length #
Length.
double get length { double sum; sum = (storage[0] * storage[0]); sum += (storage[1] * storage[1]); sum += (storage[2] * storage[2]); return Math.sqrt(sum); }
final double length2 #
Length squared.
double get length2 { double sum; sum = (storage[0] * storage[0]); sum += (storage[1] * storage[1]); sum += (storage[2] * storage[2]); return sum; }
double p #
double get p => storage[2];
set p(double arg) => storage[2] = arg;
final Vector3 ppp #
Vector3 get ppp => new Vector3(storage[2], storage[2], storage[2]);
final Vector4 pppp #
Vector4 get pppp => new Vector4(storage[2], storage[2], storage[2], storage[2]);
final Vector4 ppps #
Vector4 get ppps => new Vector4(storage[2], storage[2], storage[2], storage[0]);
final Vector4 pppt #
Vector4 get pppt => new Vector4(storage[2], storage[2], storage[2], storage[1]);
final Vector3 pps #
Vector3 get pps => new Vector3(storage[2], storage[2], storage[0]);
final Vector4 ppsp #
Vector4 get ppsp => new Vector4(storage[2], storage[2], storage[0], storage[2]);
final Vector4 ppss #
Vector4 get ppss => new Vector4(storage[2], storage[2], storage[0], storage[0]);
final Vector4 ppst #
Vector4 get ppst => new Vector4(storage[2], storage[2], storage[0], storage[1]);
final Vector3 ppt #
Vector3 get ppt => new Vector3(storage[2], storage[2], storage[1]);
final Vector4 pptp #
Vector4 get pptp => new Vector4(storage[2], storage[2], storage[1], storage[2]);
final Vector4 ppts #
Vector4 get ppts => new Vector4(storage[2], storage[2], storage[1], storage[0]);
final Vector4 pptt #
Vector4 get pptt => new Vector4(storage[2], storage[2], storage[1], storage[1]);
Vector2 ps #
Vector2 get ps => new Vector2(storage[2], storage[0]);
set ps(Vector2 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; }
final Vector3 psp #
Vector3 get psp => new Vector3(storage[2], storage[0], storage[2]);
final Vector4 pspp #
Vector4 get pspp => new Vector4(storage[2], storage[0], storage[2], storage[2]);
final Vector4 psps #
Vector4 get psps => new Vector4(storage[2], storage[0], storage[2], storage[0]);
final Vector4 pspt #
Vector4 get pspt => new Vector4(storage[2], storage[0], storage[2], storage[1]);
final Vector3 pss #
Vector3 get pss => new Vector3(storage[2], storage[0], storage[0]);
final Vector4 pssp #
Vector4 get pssp => new Vector4(storage[2], storage[0], storage[0], storage[2]);
final Vector4 psss #
Vector4 get psss => new Vector4(storage[2], storage[0], storage[0], storage[0]);
final Vector4 psst #
Vector4 get psst => new Vector4(storage[2], storage[0], storage[0], storage[1]);
Vector3 pst #
Vector3 get pst => new Vector3(storage[2], storage[0], storage[1]);
set pst(Vector3 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 pstp #
Vector4 get pstp => new Vector4(storage[2], storage[0], storage[1], storage[2]);
final Vector4 psts #
Vector4 get psts => new Vector4(storage[2], storage[0], storage[1], storage[0]);
final Vector4 pstt #
Vector4 get pstt => new Vector4(storage[2], storage[0], storage[1], storage[1]);
Vector2 pt #
Vector2 get pt => new Vector2(storage[2], storage[1]);
set pt(Vector2 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; }
final Vector3 ptp #
Vector3 get ptp => new Vector3(storage[2], storage[1], storage[2]);
final Vector4 ptpp #
Vector4 get ptpp => new Vector4(storage[2], storage[1], storage[2], storage[2]);
final Vector4 ptps #
Vector4 get ptps => new Vector4(storage[2], storage[1], storage[2], storage[0]);
final Vector4 ptpt #
Vector4 get ptpt => new Vector4(storage[2], storage[1], storage[2], storage[1]);
Vector3 pts #
Vector3 get pts => new Vector3(storage[2], storage[1], storage[0]);
set pts(Vector3 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 ptsp #
Vector4 get ptsp => new Vector4(storage[2], storage[1], storage[0], storage[2]);
final Vector4 ptss #
Vector4 get ptss => new Vector4(storage[2], storage[1], storage[0], storage[0]);
final Vector4 ptst #
Vector4 get ptst => new Vector4(storage[2], storage[1], storage[0], storage[1]);
final Vector3 ptt #
Vector3 get ptt => new Vector3(storage[2], storage[1], storage[1]);
final Vector4 pttp #
Vector4 get pttp => new Vector4(storage[2], storage[1], storage[1], storage[2]);
final Vector4 ptts #
Vector4 get ptts => new Vector4(storage[2], storage[1], storage[1], storage[0]);
final Vector4 pttt #
Vector4 get pttt => new Vector4(storage[2], storage[1], storage[1], storage[1]);
double r #
double get r => storage[0];
set r(double arg) => storage[0] = arg;
Vector2 rb #
Vector2 get rb => new Vector2(storage[0], storage[2]);
set rb(Vector2 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; }
final Vector3 rbb #
Vector3 get rbb => new Vector3(storage[0], storage[2], storage[2]);
final Vector4 rbbb #
Vector4 get rbbb => new Vector4(storage[0], storage[2], storage[2], storage[2]);
final Vector4 rbbg #
Vector4 get rbbg => new Vector4(storage[0], storage[2], storage[2], storage[1]);
final Vector4 rbbr #
Vector4 get rbbr => new Vector4(storage[0], storage[2], storage[2], storage[0]);
Vector3 rbg #
Vector3 get rbg => new Vector3(storage[0], storage[2], storage[1]);
set rbg(Vector3 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 rbgb #
Vector4 get rbgb => new Vector4(storage[0], storage[2], storage[1], storage[2]);
final Vector4 rbgg #
Vector4 get rbgg => new Vector4(storage[0], storage[2], storage[1], storage[1]);
final Vector4 rbgr #
Vector4 get rbgr => new Vector4(storage[0], storage[2], storage[1], storage[0]);
final Vector3 rbr #
Vector3 get rbr => new Vector3(storage[0], storage[2], storage[0]);
final Vector4 rbrb #
Vector4 get rbrb => new Vector4(storage[0], storage[2], storage[0], storage[2]);
final Vector4 rbrg #
Vector4 get rbrg => new Vector4(storage[0], storage[2], storage[0], storage[1]);
final Vector4 rbrr #
Vector4 get rbrr => new Vector4(storage[0], storage[2], storage[0], storage[0]);
Vector2 rg #
Vector2 get rg => new Vector2(storage[0], storage[1]);
set rg(Vector2 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; }
Vector3 rgb #
Vector3 get rgb => new Vector3(storage[0], storage[1], storage[2]);
set rgb(Vector3 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 rgbb #
Vector4 get rgbb => new Vector4(storage[0], storage[1], storage[2], storage[2]);
final Vector4 rgbg #
Vector4 get rgbg => new Vector4(storage[0], storage[1], storage[2], storage[1]);
final Vector4 rgbr #
Vector4 get rgbr => new Vector4(storage[0], storage[1], storage[2], storage[0]);
final Vector3 rgg #
Vector3 get rgg => new Vector3(storage[0], storage[1], storage[1]);
final Vector4 rggb #
Vector4 get rggb => new Vector4(storage[0], storage[1], storage[1], storage[2]);
final Vector4 rggg #
Vector4 get rggg => new Vector4(storage[0], storage[1], storage[1], storage[1]);
final Vector4 rggr #
Vector4 get rggr => new Vector4(storage[0], storage[1], storage[1], storage[0]);
final Vector3 rgr #
Vector3 get rgr => new Vector3(storage[0], storage[1], storage[0]);
final Vector4 rgrb #
Vector4 get rgrb => new Vector4(storage[0], storage[1], storage[0], storage[2]);
final Vector4 rgrg #
Vector4 get rgrg => new Vector4(storage[0], storage[1], storage[0], storage[1]);
final Vector4 rgrr #
Vector4 get rgrr => new Vector4(storage[0], storage[1], storage[0], storage[0]);
final Vector3 rrb #
Vector3 get rrb => new Vector3(storage[0], storage[0], storage[2]);
final Vector4 rrbb #
Vector4 get rrbb => new Vector4(storage[0], storage[0], storage[2], storage[2]);
final Vector4 rrbg #
Vector4 get rrbg => new Vector4(storage[0], storage[0], storage[2], storage[1]);
final Vector4 rrbr #
Vector4 get rrbr => new Vector4(storage[0], storage[0], storage[2], storage[0]);
final Vector3 rrg #
Vector3 get rrg => new Vector3(storage[0], storage[0], storage[1]);
final Vector4 rrgb #
Vector4 get rrgb => new Vector4(storage[0], storage[0], storage[1], storage[2]);
final Vector4 rrgg #
Vector4 get rrgg => new Vector4(storage[0], storage[0], storage[1], storage[1]);
final Vector4 rrgr #
Vector4 get rrgr => new Vector4(storage[0], storage[0], storage[1], storage[0]);
final Vector3 rrr #
Vector3 get rrr => new Vector3(storage[0], storage[0], storage[0]);
final Vector4 rrrb #
Vector4 get rrrb => new Vector4(storage[0], storage[0], storage[0], storage[2]);
final Vector4 rrrg #
Vector4 get rrrg => new Vector4(storage[0], storage[0], storage[0], storage[1]);
final Vector4 rrrr #
Vector4 get rrrr => new Vector4(storage[0], storage[0], storage[0], storage[0]);
double s #
double get s => storage[0];
set s(double arg) => storage[0] = arg;
Vector2 sp #
Vector2 get sp => new Vector2(storage[0], storage[2]);
set sp(Vector2 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; }
final Vector3 spp #
Vector3 get spp => new Vector3(storage[0], storage[2], storage[2]);
final Vector4 sppp #
Vector4 get sppp => new Vector4(storage[0], storage[2], storage[2], storage[2]);
final Vector4 spps #
Vector4 get spps => new Vector4(storage[0], storage[2], storage[2], storage[0]);
final Vector4 sppt #
Vector4 get sppt => new Vector4(storage[0], storage[2], storage[2], storage[1]);
final Vector3 sps #
Vector3 get sps => new Vector3(storage[0], storage[2], storage[0]);
final Vector4 spsp #
Vector4 get spsp => new Vector4(storage[0], storage[2], storage[0], storage[2]);
final Vector4 spss #
Vector4 get spss => new Vector4(storage[0], storage[2], storage[0], storage[0]);
final Vector4 spst #
Vector4 get spst => new Vector4(storage[0], storage[2], storage[0], storage[1]);
Vector3 spt #
Vector3 get spt => new Vector3(storage[0], storage[2], storage[1]);
set spt(Vector3 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 sptp #
Vector4 get sptp => new Vector4(storage[0], storage[2], storage[1], storage[2]);
final Vector4 spts #
Vector4 get spts => new Vector4(storage[0], storage[2], storage[1], storage[0]);
final Vector4 sptt #
Vector4 get sptt => new Vector4(storage[0], storage[2], storage[1], storage[1]);
final Vector3 ssp #
Vector3 get ssp => new Vector3(storage[0], storage[0], storage[2]);
final Vector4 sspp #
Vector4 get sspp => new Vector4(storage[0], storage[0], storage[2], storage[2]);
final Vector4 ssps #
Vector4 get ssps => new Vector4(storage[0], storage[0], storage[2], storage[0]);
final Vector4 sspt #
Vector4 get sspt => new Vector4(storage[0], storage[0], storage[2], storage[1]);
final Vector3 sss #
Vector3 get sss => new Vector3(storage[0], storage[0], storage[0]);
final Vector4 sssp #
Vector4 get sssp => new Vector4(storage[0], storage[0], storage[0], storage[2]);
final Vector4 ssss #
Vector4 get ssss => new Vector4(storage[0], storage[0], storage[0], storage[0]);
final Vector4 ssst #
Vector4 get ssst => new Vector4(storage[0], storage[0], storage[0], storage[1]);
final Vector3 sst #
Vector3 get sst => new Vector3(storage[0], storage[0], storage[1]);
final Vector4 sstp #
Vector4 get sstp => new Vector4(storage[0], storage[0], storage[1], storage[2]);
final Vector4 ssts #
Vector4 get ssts => new Vector4(storage[0], storage[0], storage[1], storage[0]);
final Vector4 sstt #
Vector4 get sstt => new Vector4(storage[0], storage[0], storage[1], storage[1]);
Vector2 st #
Vector2 get st => new Vector2(storage[0], storage[1]);
set st(Vector2 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; }
Vector3 stp #
Vector3 get stp => new Vector3(storage[0], storage[1], storage[2]);
set stp(Vector3 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 stpp #
Vector4 get stpp => new Vector4(storage[0], storage[1], storage[2], storage[2]);
final Vector4 stps #
Vector4 get stps => new Vector4(storage[0], storage[1], storage[2], storage[0]);
final Vector4 stpt #
Vector4 get stpt => new Vector4(storage[0], storage[1], storage[2], storage[1]);
final Vector3 sts #
Vector3 get sts => new Vector3(storage[0], storage[1], storage[0]);
final Vector4 stsp #
Vector4 get stsp => new Vector4(storage[0], storage[1], storage[0], storage[2]);
final Vector4 stss #
Vector4 get stss => new Vector4(storage[0], storage[1], storage[0], storage[0]);
final Vector4 stst #
Vector4 get stst => new Vector4(storage[0], storage[1], storage[0], storage[1]);
final Vector3 stt #
Vector3 get stt => new Vector3(storage[0], storage[1], storage[1]);
final Vector4 sttp #
Vector4 get sttp => new Vector4(storage[0], storage[1], storage[1], storage[2]);
final Vector4 stts #
Vector4 get stts => new Vector4(storage[0], storage[1], storage[1], storage[0]);
final Vector4 sttt #
Vector4 get sttt => new Vector4(storage[0], storage[1], storage[1], storage[1]);
double t #
double get t => storage[1];
set t(double arg) => storage[1] = arg;
Vector2 tp #
Vector2 get tp => new Vector2(storage[1], storage[2]);
set tp(Vector2 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; }
final Vector3 tpp #
Vector3 get tpp => new Vector3(storage[1], storage[2], storage[2]);
final Vector4 tppp #
Vector4 get tppp => new Vector4(storage[1], storage[2], storage[2], storage[2]);
final Vector4 tpps #
Vector4 get tpps => new Vector4(storage[1], storage[2], storage[2], storage[0]);
final Vector4 tppt #
Vector4 get tppt => new Vector4(storage[1], storage[2], storage[2], storage[1]);
Vector3 tps #
Vector3 get tps => new Vector3(storage[1], storage[2], storage[0]);
set tps(Vector3 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 tpsp #
Vector4 get tpsp => new Vector4(storage[1], storage[2], storage[0], storage[2]);
final Vector4 tpss #
Vector4 get tpss => new Vector4(storage[1], storage[2], storage[0], storage[0]);
final Vector4 tpst #
Vector4 get tpst => new Vector4(storage[1], storage[2], storage[0], storage[1]);
final Vector3 tpt #
Vector3 get tpt => new Vector3(storage[1], storage[2], storage[1]);
final Vector4 tptp #
Vector4 get tptp => new Vector4(storage[1], storage[2], storage[1], storage[2]);
final Vector4 tpts #
Vector4 get tpts => new Vector4(storage[1], storage[2], storage[1], storage[0]);
final Vector4 tptt #
Vector4 get tptt => new Vector4(storage[1], storage[2], storage[1], storage[1]);
Vector2 ts #
Vector2 get ts => new Vector2(storage[1], storage[0]);
set ts(Vector2 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; }
Vector3 tsp #
Vector3 get tsp => new Vector3(storage[1], storage[0], storage[2]);
set tsp(Vector3 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 tspp #
Vector4 get tspp => new Vector4(storage[1], storage[0], storage[2], storage[2]);
final Vector4 tsps #
Vector4 get tsps => new Vector4(storage[1], storage[0], storage[2], storage[0]);
final Vector4 tspt #
Vector4 get tspt => new Vector4(storage[1], storage[0], storage[2], storage[1]);
final Vector3 tss #
Vector3 get tss => new Vector3(storage[1], storage[0], storage[0]);
final Vector4 tssp #
Vector4 get tssp => new Vector4(storage[1], storage[0], storage[0], storage[2]);
final Vector4 tsss #
Vector4 get tsss => new Vector4(storage[1], storage[0], storage[0], storage[0]);
final Vector4 tsst #
Vector4 get tsst => new Vector4(storage[1], storage[0], storage[0], storage[1]);
final Vector3 tst #
Vector3 get tst => new Vector3(storage[1], storage[0], storage[1]);
final Vector4 tstp #
Vector4 get tstp => new Vector4(storage[1], storage[0], storage[1], storage[2]);
final Vector4 tsts #
Vector4 get tsts => new Vector4(storage[1], storage[0], storage[1], storage[0]);
final Vector4 tstt #
Vector4 get tstt => new Vector4(storage[1], storage[0], storage[1], storage[1]);
final Vector3 ttp #
Vector3 get ttp => new Vector3(storage[1], storage[1], storage[2]);
final Vector4 ttpp #
Vector4 get ttpp => new Vector4(storage[1], storage[1], storage[2], storage[2]);
final Vector4 ttps #
Vector4 get ttps => new Vector4(storage[1], storage[1], storage[2], storage[0]);
final Vector4 ttpt #
Vector4 get ttpt => new Vector4(storage[1], storage[1], storage[2], storage[1]);
final Vector3 tts #
Vector3 get tts => new Vector3(storage[1], storage[1], storage[0]);
final Vector4 ttsp #
Vector4 get ttsp => new Vector4(storage[1], storage[1], storage[0], storage[2]);
final Vector4 ttss #
Vector4 get ttss => new Vector4(storage[1], storage[1], storage[0], storage[0]);
final Vector4 ttst #
Vector4 get ttst => new Vector4(storage[1], storage[1], storage[0], storage[1]);
final Vector3 ttt #
Vector3 get ttt => new Vector3(storage[1], storage[1], storage[1]);
final Vector4 tttp #
Vector4 get tttp => new Vector4(storage[1], storage[1], storage[1], storage[2]);
final Vector4 ttts #
Vector4 get ttts => new Vector4(storage[1], storage[1], storage[1], storage[0]);
final Vector4 tttt #
Vector4 get tttt => new Vector4(storage[1], storage[1], storage[1], storage[1]);
double x #
double get x => storage[0];
set x(double arg) => storage[0] = arg;
final Vector3 xxx #
Vector3 get xxx => new Vector3(storage[0], storage[0], storage[0]);
final Vector4 xxxx #
Vector4 get xxxx => new Vector4(storage[0], storage[0], storage[0], storage[0]);
final Vector4 xxxy #
Vector4 get xxxy => new Vector4(storage[0], storage[0], storage[0], storage[1]);
final Vector4 xxxz #
Vector4 get xxxz => new Vector4(storage[0], storage[0], storage[0], storage[2]);
final Vector3 xxy #
Vector3 get xxy => new Vector3(storage[0], storage[0], storage[1]);
final Vector4 xxyx #
Vector4 get xxyx => new Vector4(storage[0], storage[0], storage[1], storage[0]);
final Vector4 xxyy #
Vector4 get xxyy => new Vector4(storage[0], storage[0], storage[1], storage[1]);
final Vector4 xxyz #
Vector4 get xxyz => new Vector4(storage[0], storage[0], storage[1], storage[2]);
final Vector3 xxz #
Vector3 get xxz => new Vector3(storage[0], storage[0], storage[2]);
final Vector4 xxzx #
Vector4 get xxzx => new Vector4(storage[0], storage[0], storage[2], storage[0]);
final Vector4 xxzy #
Vector4 get xxzy => new Vector4(storage[0], storage[0], storage[2], storage[1]);
final Vector4 xxzz #
Vector4 get xxzz => new Vector4(storage[0], storage[0], storage[2], storage[2]);
Vector2 xy #
Vector2 get xy => new Vector2(storage[0], storage[1]);
set xy(Vector2 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; }
final Vector3 xyx #
Vector3 get xyx => new Vector3(storage[0], storage[1], storage[0]);
final Vector4 xyxx #
Vector4 get xyxx => new Vector4(storage[0], storage[1], storage[0], storage[0]);
final Vector4 xyxy #
Vector4 get xyxy => new Vector4(storage[0], storage[1], storage[0], storage[1]);
final Vector4 xyxz #
Vector4 get xyxz => new Vector4(storage[0], storage[1], storage[0], storage[2]);
final Vector3 xyy #
Vector3 get xyy => new Vector3(storage[0], storage[1], storage[1]);
final Vector4 xyyx #
Vector4 get xyyx => new Vector4(storage[0], storage[1], storage[1], storage[0]);
final Vector4 xyyy #
Vector4 get xyyy => new Vector4(storage[0], storage[1], storage[1], storage[1]);
final Vector4 xyyz #
Vector4 get xyyz => new Vector4(storage[0], storage[1], storage[1], storage[2]);
Vector3 xyz #
Vector3 get xyz => new Vector3(storage[0], storage[1], storage[2]);
set xyz(Vector3 arg) { storage[0] = arg.storage[0]; storage[1] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 xyzx #
Vector4 get xyzx => new Vector4(storage[0], storage[1], storage[2], storage[0]);
final Vector4 xyzy #
Vector4 get xyzy => new Vector4(storage[0], storage[1], storage[2], storage[1]);
final Vector4 xyzz #
Vector4 get xyzz => new Vector4(storage[0], storage[1], storage[2], storage[2]);
Vector2 xz #
Vector2 get xz => new Vector2(storage[0], storage[2]);
set xz(Vector2 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; }
final Vector3 xzx #
Vector3 get xzx => new Vector3(storage[0], storage[2], storage[0]);
final Vector4 xzxx #
Vector4 get xzxx => new Vector4(storage[0], storage[2], storage[0], storage[0]);
final Vector4 xzxy #
Vector4 get xzxy => new Vector4(storage[0], storage[2], storage[0], storage[1]);
final Vector4 xzxz #
Vector4 get xzxz => new Vector4(storage[0], storage[2], storage[0], storage[2]);
Vector3 xzy #
Vector3 get xzy => new Vector3(storage[0], storage[2], storage[1]);
set xzy(Vector3 arg) { storage[0] = arg.storage[0]; storage[2] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 xzyx #
Vector4 get xzyx => new Vector4(storage[0], storage[2], storage[1], storage[0]);
final Vector4 xzyy #
Vector4 get xzyy => new Vector4(storage[0], storage[2], storage[1], storage[1]);
final Vector4 xzyz #
Vector4 get xzyz => new Vector4(storage[0], storage[2], storage[1], storage[2]);
final Vector3 xzz #
Vector3 get xzz => new Vector3(storage[0], storage[2], storage[2]);
final Vector4 xzzx #
Vector4 get xzzx => new Vector4(storage[0], storage[2], storage[2], storage[0]);
final Vector4 xzzy #
Vector4 get xzzy => new Vector4(storage[0], storage[2], storage[2], storage[1]);
final Vector4 xzzz #
Vector4 get xzzz => new Vector4(storage[0], storage[2], storage[2], storage[2]);
double y #
double get y => storage[1];
set y(double arg) => storage[1] = arg;
Vector2 yx #
Vector2 get yx => new Vector2(storage[1], storage[0]);
set yx(Vector2 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; }
final Vector3 yxx #
Vector3 get yxx => new Vector3(storage[1], storage[0], storage[0]);
final Vector4 yxxx #
Vector4 get yxxx => new Vector4(storage[1], storage[0], storage[0], storage[0]);
final Vector4 yxxy #
Vector4 get yxxy => new Vector4(storage[1], storage[0], storage[0], storage[1]);
final Vector4 yxxz #
Vector4 get yxxz => new Vector4(storage[1], storage[0], storage[0], storage[2]);
final Vector3 yxy #
Vector3 get yxy => new Vector3(storage[1], storage[0], storage[1]);
final Vector4 yxyx #
Vector4 get yxyx => new Vector4(storage[1], storage[0], storage[1], storage[0]);
final Vector4 yxyy #
Vector4 get yxyy => new Vector4(storage[1], storage[0], storage[1], storage[1]);
final Vector4 yxyz #
Vector4 get yxyz => new Vector4(storage[1], storage[0], storage[1], storage[2]);
Vector3 yxz #
Vector3 get yxz => new Vector3(storage[1], storage[0], storage[2]);
set yxz(Vector3 arg) { storage[1] = arg.storage[0]; storage[0] = arg.storage[1]; storage[2] = arg.storage[2]; }
final Vector4 yxzx #
Vector4 get yxzx => new Vector4(storage[1], storage[0], storage[2], storage[0]);
final Vector4 yxzy #
Vector4 get yxzy => new Vector4(storage[1], storage[0], storage[2], storage[1]);
final Vector4 yxzz #
Vector4 get yxzz => new Vector4(storage[1], storage[0], storage[2], storage[2]);
final Vector3 yyx #
Vector3 get yyx => new Vector3(storage[1], storage[1], storage[0]);
final Vector4 yyxx #
Vector4 get yyxx => new Vector4(storage[1], storage[1], storage[0], storage[0]);
final Vector4 yyxy #
Vector4 get yyxy => new Vector4(storage[1], storage[1], storage[0], storage[1]);
final Vector4 yyxz #
Vector4 get yyxz => new Vector4(storage[1], storage[1], storage[0], storage[2]);
final Vector3 yyy #
Vector3 get yyy => new Vector3(storage[1], storage[1], storage[1]);
final Vector4 yyyx #
Vector4 get yyyx => new Vector4(storage[1], storage[1], storage[1], storage[0]);
final Vector4 yyyy #
Vector4 get yyyy => new Vector4(storage[1], storage[1], storage[1], storage[1]);
final Vector4 yyyz #
Vector4 get yyyz => new Vector4(storage[1], storage[1], storage[1], storage[2]);
final Vector3 yyz #
Vector3 get yyz => new Vector3(storage[1], storage[1], storage[2]);
final Vector4 yyzx #
Vector4 get yyzx => new Vector4(storage[1], storage[1], storage[2], storage[0]);
final Vector4 yyzy #
Vector4 get yyzy => new Vector4(storage[1], storage[1], storage[2], storage[1]);
final Vector4 yyzz #
Vector4 get yyzz => new Vector4(storage[1], storage[1], storage[2], storage[2]);
Vector2 yz #
Vector2 get yz => new Vector2(storage[1], storage[2]);
set yz(Vector2 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; }
Vector3 yzx #
Vector3 get yzx => new Vector3(storage[1], storage[2], storage[0]);
set yzx(Vector3 arg) { storage[1] = arg.storage[0]; storage[2] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 yzxx #
Vector4 get yzxx => new Vector4(storage[1], storage[2], storage[0], storage[0]);
final Vector4 yzxy #
Vector4 get yzxy => new Vector4(storage[1], storage[2], storage[0], storage[1]);
final Vector4 yzxz #
Vector4 get yzxz => new Vector4(storage[1], storage[2], storage[0], storage[2]);
final Vector3 yzy #
Vector3 get yzy => new Vector3(storage[1], storage[2], storage[1]);
final Vector4 yzyx #
Vector4 get yzyx => new Vector4(storage[1], storage[2], storage[1], storage[0]);
final Vector4 yzyy #
Vector4 get yzyy => new Vector4(storage[1], storage[2], storage[1], storage[1]);
final Vector4 yzyz #
Vector4 get yzyz => new Vector4(storage[1], storage[2], storage[1], storage[2]);
final Vector3 yzz #
Vector3 get yzz => new Vector3(storage[1], storage[2], storage[2]);
final Vector4 yzzx #
Vector4 get yzzx => new Vector4(storage[1], storage[2], storage[2], storage[0]);
final Vector4 yzzy #
Vector4 get yzzy => new Vector4(storage[1], storage[2], storage[2], storage[1]);
final Vector4 yzzz #
Vector4 get yzzz => new Vector4(storage[1], storage[2], storage[2], storage[2]);
double z #
double get z => storage[2];
set z(double arg) => storage[2] = arg;
Vector2 zx #
Vector2 get zx => new Vector2(storage[2], storage[0]);
set zx(Vector2 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; }
final Vector3 zxx #
Vector3 get zxx => new Vector3(storage[2], storage[0], storage[0]);
final Vector4 zxxx #
Vector4 get zxxx => new Vector4(storage[2], storage[0], storage[0], storage[0]);
final Vector4 zxxy #
Vector4 get zxxy => new Vector4(storage[2], storage[0], storage[0], storage[1]);
final Vector4 zxxz #
Vector4 get zxxz => new Vector4(storage[2], storage[0], storage[0], storage[2]);
Vector3 zxy #
Vector3 get zxy => new Vector3(storage[2], storage[0], storage[1]);
set zxy(Vector3 arg) { storage[2] = arg.storage[0]; storage[0] = arg.storage[1]; storage[1] = arg.storage[2]; }
final Vector4 zxyx #
Vector4 get zxyx => new Vector4(storage[2], storage[0], storage[1], storage[0]);
final Vector4 zxyy #
Vector4 get zxyy => new Vector4(storage[2], storage[0], storage[1], storage[1]);
final Vector4 zxyz #
Vector4 get zxyz => new Vector4(storage[2], storage[0], storage[1], storage[2]);
final Vector3 zxz #
Vector3 get zxz => new Vector3(storage[2], storage[0], storage[2]);
final Vector4 zxzx #
Vector4 get zxzx => new Vector4(storage[2], storage[0], storage[2], storage[0]);
final Vector4 zxzy #
Vector4 get zxzy => new Vector4(storage[2], storage[0], storage[2], storage[1]);
final Vector4 zxzz #
Vector4 get zxzz => new Vector4(storage[2], storage[0], storage[2], storage[2]);
Vector2 zy #
Vector2 get zy => new Vector2(storage[2], storage[1]);
set zy(Vector2 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; }
Vector3 zyx #
Vector3 get zyx => new Vector3(storage[2], storage[1], storage[0]);
set zyx(Vector3 arg) { storage[2] = arg.storage[0]; storage[1] = arg.storage[1]; storage[0] = arg.storage[2]; }
final Vector4 zyxx #
Vector4 get zyxx => new Vector4(storage[2], storage[1], storage[0], storage[0]);
final Vector4 zyxy #
Vector4 get zyxy => new Vector4(storage[2], storage[1], storage[0], storage[1]);
final Vector4 zyxz #
Vector4 get zyxz => new Vector4(storage[2], storage[1], storage[0], storage[2]);
final Vector3 zyy #
Vector3 get zyy => new Vector3(storage[2], storage[1], storage[1]);
final Vector4 zyyx #
Vector4 get zyyx => new Vector4(storage[2], storage[1], storage[1], storage[0]);
final Vector4 zyyy #
Vector4 get zyyy => new Vector4(storage[2], storage[1], storage[1], storage[1]);
final Vector4 zyyz #
Vector4 get zyyz => new Vector4(storage[2], storage[1], storage[1], storage[2]);
final Vector3 zyz #
Vector3 get zyz => new Vector3(storage[2], storage[1], storage[2]);
final Vector4 zyzx #
Vector4 get zyzx => new Vector4(storage[2], storage[1], storage[2], storage[0]);
final Vector4 zyzy #
Vector4 get zyzy => new Vector4(storage[2], storage[1], storage[2], storage[1]);
final Vector4 zyzz #
Vector4 get zyzz => new Vector4(storage[2], storage[1], storage[2], storage[2]);
final Vector3 zzx #
Vector3 get zzx => new Vector3(storage[2], storage[2], storage[0]);
final Vector4 zzxx #
Vector4 get zzxx => new Vector4(storage[2], storage[2], storage[0], storage[0]);
final Vector4 zzxy #
Vector4 get zzxy => new Vector4(storage[2], storage[2], storage[0], storage[1]);
final Vector4 zzxz #
Vector4 get zzxz => new Vector4(storage[2], storage[2], storage[0], storage[2]);
final Vector3 zzy #
Vector3 get zzy => new Vector3(storage[2], storage[2], storage[1]);
final Vector4 zzyx #
Vector4 get zzyx => new Vector4(storage[2], storage[2], storage[1], storage[0]);
final Vector4 zzyy #
Vector4 get zzyy => new Vector4(storage[2], storage[2], storage[1], storage[1]);
final Vector4 zzyz #
Vector4 get zzyz => new Vector4(storage[2], storage[2], storage[1], storage[2]);
final Vector3 zzz #
Vector3 get zzz => new Vector3(storage[2], storage[2], storage[2]);
final Vector4 zzzx #
Vector4 get zzzx => new Vector4(storage[2], storage[2], storage[2], storage[0]);
Operators
void operator []=(int i, double v) #
void operator[]=(int i, double v) { storage[i] = v; }
Vector3 operator +(Vector3 other) #
Add two vectors.
Vector3 operator+(Vector3 other) => new Vector3(storage[0] + other.storage[0], storage[1] + other.storage[1], storage[2] + other.storage[2]);
Vector3 operator -() #
Negate
Vector3 operator-() => new Vector3(- storage[0], - storage[1], - storage[2]);
Vector3 operator -(Vector3 other) #
Subtract two vectors.
Vector3 operator-(Vector3 other) => new Vector3(storage[0] - other.storage[0], storage[1] - other.storage[1], storage[2] - other.storage[2]);
Methods
Vector3 absolute() #
Absolute value.
Vector3 absolute() { storage[0] = storage[0].abs(); storage[1] = storage[1].abs(); storage[2] = storage[2].abs(); return this; }
double absoluteError(Vector3 correct) #
Absolute error between this
and
correct
double absoluteError(Vector3 correct) { return (this - correct).length; }
Vector3 add(Vector3 arg) #
Add
arg to this
.
Vector3 add(Vector3 arg) { storage[0] = storage[0] + arg.storage[0]; storage[1] = storage[1] + arg.storage[1]; storage[2] = storage[2] + arg.storage[2]; return this; }
Vector3 applyProjection(Matrix4 arg) #
Projects this
using the projection matrix
arg
Vector3 applyProjection(Matrix4 arg) { double _x = storage[0]; double _y = storage[1]; double _z = storage[2]; double d = 1.0 / (arg.storage[3] * _x + arg.storage[7] * _y + arg.storage[11] * _z + arg.storage[15]); storage[0] = (arg.storage[0] * _x + arg.storage[4] * _y + arg.storage[8] * _z + arg.storage[12]) * d; storage[1] = (arg.storage[1] * _x + arg.storage[5] * _y + arg.storage[9] * _z + arg.storage[13]) * d; storage[2] = (arg.storage[2] * _x + arg.storage[6] * _y + arg.storage[10] * _z + arg.storage[14]) * d; return this; }
Vector3 clone() #
Clone of this
.
Vector3 clone() { return new Vector3.copy(this); }
void copyFromArray(List<double> array, [int offset = 0]) #
Copies elements from
array into this
starting at
offset.
void copyFromArray(List<double> array, [int offset=0]) { storage[2] = array[offset+2]; storage[1] = array[offset+1]; storage[0] = array[offset+0]; }
Vector3 copyInto(Vector3 arg) #
Vector3 copyInto(Vector3 arg) { arg.storage[0] = storage[0]; arg.storage[1] = storage[1]; arg.storage[2] = storage[2]; return arg; }
void copyIntoArray(List<double> array, [int offset = 0]) #
Copies this
into
array starting at
offset.
void copyIntoArray(List<double> array, [int offset=0]) { array[offset+2] = storage[2]; array[offset+1] = storage[1]; array[offset+0] = storage[0]; }
Vector3 cross(Vector3 other) #
Cross product.
Vector3 cross(Vector3 other) { double _x = storage[0]; double _y = storage[1]; double _z = storage[2]; double ox = other.storage[0]; double oy = other.storage[1]; double oz = other.storage[2]; return new Vector3(_y * oz - _z * oy, _z * ox - _x * oz, _x * oy - _y * ox); }
Vector3 crossInto(Vector3 other, Vector3 out) #
Cross product. Stores result in out.
Vector3 crossInto(Vector3 other, Vector3 out) { double _x = storage[0]; double _y = storage[1]; double _z = storage[2]; double ox = other.storage[0]; double oy = other.storage[1]; double oz = other.storage[2]; out.storage[0] = _y * oz - _z * oy; out.storage[1] = _z * ox - _x * oz; out.storage[2] = _x * oy - _y * ox; return out; }
Vector3 divide(Vector3 arg) #
Divide entries in this
with entries in
arg.
Vector3 divide(Vector3 arg) { storage[0] = storage[0] / arg.storage[0]; storage[1] = storage[1] / arg.storage[1]; storage[2] = storage[2] / arg.storage[2]; return this; }
double dot(Vector3 other) #
Inner product.
double dot(Vector3 other) { double sum; sum = storage[0] * other.storage[0]; sum += storage[1] * other.storage[1]; sum += storage[2] * other.storage[2]; return sum; }
Vector3 multiply(Vector3 arg) #
Multiply entries in this
with entries in
arg.
Vector3 multiply(Vector3 arg) { storage[0] = storage[0] * arg.storage[0]; storage[1] = storage[1] * arg.storage[1]; storage[2] = storage[2] * arg.storage[2]; return this; }
Vector3 negate() #
Vector3 negate() { storage[2] = -storage[2]; storage[1] = -storage[1]; storage[0] = -storage[0]; return this; }
Vector3 normalize() #
Normalizes this
.
Vector3 normalize() { double l = length; if (l == 0.0) { return this; } l = 1.0 / l; storage[0] *= l; storage[1] *= l; storage[2] *= l; return this; }
Vector3 normalized() #
Normalizes copy of this
.
Vector3 normalized() { return new Vector3.copy(this).normalize(); }
Vector3 normalizeInto(Vector3 out) #
Normalize vector into out.
Vector3 normalizeInto(Vector3 out) { out.setFrom(this); return out.normalize(); }
double normalizeLength() #
Normalize this
. Returns length of vector before normalization.
double normalizeLength() { double l = length; if (l == 0.0) { return 0.0; } l = 1.0 / l; storage[0] *= l; storage[1] *= l; storage[2] *= l; return l; }
Vector3 reflect(Vector3 normal) #
Reflect this
.
Vector3 reflect(Vector3 normal) { sub(normal.scaled(2 * normal.dot(this))); return this; }
Vector3 reflected(Vector3 normal) #
Reflected copy of this
.
Vector3 reflected(Vector3 normal) { return new Vector3.copy(this).reflect(normal); }
double relativeError(Vector3 correct) #
Relative error between this
and
correct
double relativeError(Vector3 correct) { double correct_norm = correct.length; double diff_norm = (this - correct).length; return diff_norm/correct_norm; }
Vector3 scale(double arg) #
Scale this
.
Vector3 scale(double arg) { storage[2] = storage[2] * arg; storage[1] = storage[1] * arg; storage[0] = storage[0] * arg; return this; }
Vector3 scaled(double arg) #
Vector3 scaled(double arg) { return clone().scale(arg); }
Vector3 setFrom(Vector3 other) #
Set the values by copying them from other.
Vector3 setFrom(Vector3 other) { storage[0] = other.storage[0]; storage[1] = other.storage[1]; storage[2] = other.storage[2]; return this; }
Vector3 setValues(double x_, double y_, double z_) #
Set the values of the vector.
Vector3 setValues(double x_, double y_, double z_) { storage[0] = x_; storage[1] = y_; storage[2] = z_; return this; }
Vector3 setZero() #
Zero vector.
Vector3 setZero() { storage[2] = 0.0; storage[1] = 0.0; storage[0] = 0.0; return this; }
Vector3 splat(double arg) #
Splat arg into all lanes of the vector.
Vector3 splat(double arg) { storage[2] = arg; storage[1] = arg; storage[0] = arg; return this; }