Swizzle

Undocumented in source.

Constructors

this
this(CompSwizzle r, CompSwizzle g, CompSwizzle b, CompSwizzle a)
Undocumented in source.

Members

Functions

opDollar
size_t opDollar()
Undocumented in source. Be warned that the author may not have intended to support it.
opIndex
CompSwizzle opIndex(size_t ind)
Undocumented in source. Be warned that the author may not have intended to support it.
opIndex
const(CompSwizzle)[] opIndex()
Undocumented in source. Be warned that the author may not have intended to support it.
opIndex
const(CompSwizzle)[] opIndex(size_t[2] slice)
Undocumented in source. Be warned that the author may not have intended to support it.
opSlice
size_t[2] opSlice(size_t start, size_t end)
Undocumented in source. Be warned that the author may not have intended to support it.

Properties

identity
Swizzle identity [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
one
Swizzle one [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
opDispatch
Swizzle opDispatch [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
zero
Swizzle zero [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Examples

assert(!__traits(compiles, Swizzle.rrr));
assert(!__traits(compiles, Swizzle.qwer));

assert(Swizzle.rgba == Swizzle(CompSwizzle.r, CompSwizzle.g, CompSwizzle.b, CompSwizzle.a));
assert(Swizzle.rrbb == Swizzle(CompSwizzle.r, CompSwizzle.r, CompSwizzle.b, CompSwizzle.b));
assert(Swizzle.aaag == Swizzle(CompSwizzle.a, CompSwizzle.a, CompSwizzle.a, CompSwizzle.g));
assert(Swizzle.iiii == Swizzle.identity);
assert(Swizzle.oooo == Swizzle.one);
assert(Swizzle.zzzz == Swizzle.zero);

Meta