Skip to content

v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:553

Interface representing its WGSL vector type counterpart: vec3u or vec3. A vector with 3 elements of type u32

  • Tuple3<number>.Swizzle3<v2u, v3u, v4u>.vecInfixNotation<v3u>

[n: number]: number

readonly [$internal]: true

Defined in: packages/typegpu/src/data/wgslTypes.ts:555


readonly [unscopables]: object

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts:97

Is an object whose properties have the value ‘true’ when they will be absent when used in a ‘with’ statement.

[key: number]: undefined | boolean

optional [iterator]: boolean

readonly optional [unscopables]: boolean

Is an object whose properties have the value ‘true’ when they will be absent when used in a ‘with’ statement.

optional at: boolean

optional concat: boolean

optional copyWithin: boolean

optional entries: boolean

optional every: boolean

optional fill: boolean

optional filter: boolean

optional find: boolean

optional findIndex: boolean

optional findLast: boolean

optional findLastIndex: boolean

optional flat: boolean

optional flatMap: boolean

optional forEach: boolean

optional includes: boolean

optional indexOf: boolean

optional join: boolean

optional keys: boolean

optional lastIndexOf: boolean

optional length: boolean

Gets or sets the length of the array. This is a number one higher than the highest index in the array.

optional map: boolean

optional pop: boolean

optional push: boolean

optional reduce: boolean

optional reduceRight: boolean

optional reverse: boolean

optional shift: boolean

optional slice: boolean

optional some: boolean

optional sort: boolean

optional splice: boolean

optional toLocaleString: boolean

optional toReversed: boolean

optional toSorted: boolean

optional toSpliced: boolean

optional toString: boolean

optional unshift: boolean

optional values: boolean

optional with: boolean

Tuple3.[unscopables]


0: number

Tuple3.0


1: number

Tuple3.1


2: number

Tuple3.2


readonly kind: "vec3u"

Defined in: packages/typegpu/src/data/wgslTypes.ts:557

use to distinguish between vectors of the same size on the type level


length: 3

Tuple3.length


x: number

Defined in: packages/typegpu/src/data/wgslTypes.ts:558


readonly xx: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:126

Swizzle3.xx


readonly xxx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:131

Swizzle3.xxx


readonly xxxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:140

Swizzle3.xxxx


readonly xxxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:141

Swizzle3.xxxy


readonly xxxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:185

Swizzle3.xxxz


readonly xxy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:132

Swizzle3.xxy


readonly xxyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:142

Swizzle3.xxyx


readonly xxyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:143

Swizzle3.xxyy


readonly xxyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:186

Swizzle3.xxyz


readonly xxz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:165

Swizzle3.xxz


readonly xxzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:187

Swizzle3.xxzx


readonly xxzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:188

Swizzle3.xxzy


readonly xxzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:189

Swizzle3.xxzz


readonly xy: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:127

Swizzle3.xy


readonly xyx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:133

Swizzle3.xyx


readonly xyxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:144

Swizzle3.xyxx


readonly xyxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:145

Swizzle3.xyxy


readonly xyxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:190

Swizzle3.xyxz


readonly xyy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:134

Swizzle3.xyy


readonly xyyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:146

Swizzle3.xyyx


readonly xyyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:147

Swizzle3.xyyy


readonly xyyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:191

Swizzle3.xyyz


readonly xyz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:166

Swizzle3.xyz


readonly xyzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:192

Swizzle3.xyzx


readonly xyzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:193

Swizzle3.xyzy


readonly xyzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:194

Swizzle3.xyzz


readonly xz: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:159

Swizzle3.xz


readonly xzx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:167

Swizzle3.xzx


readonly xzxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:195

Swizzle3.xzxx


readonly xzxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:196

Swizzle3.xzxy


readonly xzxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:197

Swizzle3.xzxz


readonly xzy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:168

Swizzle3.xzy


readonly xzyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:198

Swizzle3.xzyx


readonly xzyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:199

Swizzle3.xzyy


readonly xzyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:200

Swizzle3.xzyz


readonly xzz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:169

Swizzle3.xzz


readonly xzzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:201

Swizzle3.xzzx


readonly xzzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:202

Swizzle3.xzzy


readonly xzzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:203

Swizzle3.xzzz


y: number

Defined in: packages/typegpu/src/data/wgslTypes.ts:559


readonly yx: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:128

Swizzle3.yx


readonly yxx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:135

Swizzle3.yxx


readonly yxxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:148

Swizzle3.yxxx


readonly yxxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:149

Swizzle3.yxxy


readonly yxxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:204

Swizzle3.yxxz


readonly yxy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:136

Swizzle3.yxy


readonly yxyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:150

Swizzle3.yxyx


readonly yxyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:151

Swizzle3.yxyy


readonly yxyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:205

Swizzle3.yxyz


readonly yxz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:170

Swizzle3.yxz


readonly yxzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:206

Swizzle3.yxzx


readonly yxzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:207

Swizzle3.yxzy


readonly yxzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:208

Swizzle3.yxzz


readonly yy: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:129

Swizzle3.yy


readonly yyx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:137

Swizzle3.yyx


readonly yyxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:152

Swizzle3.yyxx


readonly yyxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:153

Swizzle3.yyxy


readonly yyxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:209

Swizzle3.yyxz


readonly yyy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:138

Swizzle3.yyy


readonly yyyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:154

Swizzle3.yyyx


readonly yyyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:155

Swizzle3.yyyy


readonly yyyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:210

Swizzle3.yyyz


readonly yyz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:171

Swizzle3.yyz


readonly yyzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:211

Swizzle3.yyzx


readonly yyzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:212

Swizzle3.yyzy


readonly yyzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:213

Swizzle3.yyzz


readonly yz: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:160

Swizzle3.yz


readonly yzx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:172

Swizzle3.yzx


readonly yzxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:214

Swizzle3.yzxx


readonly yzxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:215

Swizzle3.yzxy


readonly yzxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:216

Swizzle3.yzxz


readonly yzy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:173

Swizzle3.yzy


readonly yzyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:217

Swizzle3.yzyx


readonly yzyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:218

Swizzle3.yzyy


readonly yzyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:219

Swizzle3.yzyz


readonly yzz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:174

Swizzle3.yzz


readonly yzzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:220

Swizzle3.yzzx


readonly yzzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:221

Swizzle3.yzzy


readonly yzzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:222

Swizzle3.yzzz


z: number

Defined in: packages/typegpu/src/data/wgslTypes.ts:560


readonly zx: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:161

Swizzle3.zx


readonly zxx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:175

Swizzle3.zxx


readonly zxxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:223

Swizzle3.zxxx


readonly zxxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:224

Swizzle3.zxxy


readonly zxxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:225

Swizzle3.zxxz


readonly zxy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:176

Swizzle3.zxy


readonly zxyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:226

Swizzle3.zxyx


readonly zxyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:227

Swizzle3.zxyy


readonly zxyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:228

Swizzle3.zxyz


readonly zxz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:177

Swizzle3.zxz


readonly zxzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:229

Swizzle3.zxzx


readonly zxzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:230

Swizzle3.zxzy


readonly zxzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:231

Swizzle3.zxzz


readonly zy: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:162

Swizzle3.zy


readonly zyx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:178

Swizzle3.zyx


readonly zyxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:232

Swizzle3.zyxx


readonly zyxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:233

Swizzle3.zyxy


readonly zyxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:234

Swizzle3.zyxz


readonly zyy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:179

Swizzle3.zyy


readonly zyyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:235

Swizzle3.zyyx


readonly zyyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:236

Swizzle3.zyyy


readonly zyyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:237

Swizzle3.zyyz


readonly zyz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:180

Swizzle3.zyz


readonly zyzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:238

Swizzle3.zyzx


readonly zyzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:239

Swizzle3.zyzy


readonly zyzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:240

Swizzle3.zyzz


readonly zz: v2u

Defined in: packages/typegpu/src/data/wgslTypes.ts:163

Swizzle3.zz


readonly zzx: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:181

Swizzle3.zzx


readonly zzxx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:241

Swizzle3.zzxx


readonly zzxy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:242

Swizzle3.zzxy


readonly zzxz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:243

Swizzle3.zzxz


readonly zzy: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:182

Swizzle3.zzy


readonly zzyx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:244

Swizzle3.zzyx


readonly zzyy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:245

Swizzle3.zzyy


readonly zzyz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:246

Swizzle3.zzyz


readonly zzz: v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:183

Swizzle3.zzz


readonly zzzx: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:247

Swizzle3.zzzx


readonly zzzy: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:248

Swizzle3.zzzy


readonly zzzz: v4u

Defined in: packages/typegpu/src/data/wgslTypes.ts:249

Swizzle3.zzzz

[iterator](): ArrayIterator<number>

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.iterable.d.ts:78

Iterator

ArrayIterator<number>

Tuple3.[iterator]


add(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:51

number

v3u

vecInfixNotation.add

add(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:52

v3u

v3u

vecInfixNotation.add


at(index): undefined | number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2022.array.d.ts:24

Returns the item located at the specified index.

number

The zero-based index of the desired code unit. A negative index will count back from the last item.

undefined | number

Tuple3.at


concat(…items): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1350

Combines two or more arrays. This method returns a new array without modifying any existing arrays.

ConcatArray<number>[]

Additional arrays and/or items to add to the end of the array.

number[]

Tuple3.concat

concat(…items): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1356

Combines two or more arrays. This method returns a new array without modifying any existing arrays.

…(number | ConcatArray<number>)[]

Additional arrays and/or items to add to the end of the array.

number[]

Tuple3.concat


copyWithin(target, start, end?): this

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:62

Returns the this object after copying a section of the array identified by start and end to the same array starting at position target

number

If target is negative, it is treated as length+target where length is the length of the array.

number

If start is negative, it is treated as length+start. If end is negative, it is treated as length+end.

number

If not specified, length of the this object is used as its default value.

this

Tuple3.copyWithin


div(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:61

number

v3u

vecInfixNotation.div

div(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:62

v3u

v3u

vecInfixNotation.div


entries(): ArrayIterator<[number, number]>

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.iterable.d.ts:83

Returns an iterable of key, value pairs for every entry in the array

ArrayIterator<[number, number]>

Tuple3.entries


every<S>(predicate, thisArg?): this is S[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1433

Determines whether all the members of an array satisfy the specified test.

S extends number

(value, index, array) => value is S

A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.

any

An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

this is S[]

Tuple3.every

every(predicate, thisArg?): boolean

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1442

Determines whether all the members of an array satisfy the specified test.

(value, index, array) => unknown

A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.

any

An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

boolean

Tuple3.every


fill(value, start?, end?): this

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:51

Changes all array elements from start to end index to a static value and returns the modified array

number

value to fill array section with

number

index to start filling the array at. If start is negative, it is treated as length+start where length is the length of the array.

number

index to stop filling the array at. If end is negative, it is treated as length+end.

this

Tuple3.fill


filter<S>(predicate, thisArg?): S[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1469

Returns the elements of an array that meet the condition specified in a callback function.

S extends number

(value, index, array) => value is S

A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.

any

An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

S[]

Tuple3.filter

filter(predicate, thisArg?): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1475

Returns the elements of an array that meet the condition specified in a callback function.

(value, index, array) => unknown

A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.

any

An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

number[]

Tuple3.filter


find<S>(predicate, thisArg?): undefined | S

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:29

Returns the value of the first element in the array where predicate is true, and undefined otherwise.

S extends number

(value, index, obj) => value is S

find calls predicate once for each element of the array, in ascending order, until it finds one where predicate returns true. If such an element is found, find immediately returns that element value. Otherwise, find returns undefined.

any

If provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.

undefined | S

Tuple3.find

find(predicate, thisArg?): undefined | number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:30

(value, index, obj) => unknown

any

undefined | number

Tuple3.find


findIndex(predicate, thisArg?): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:41

Returns the index of the first element in the array where predicate is true, and -1 otherwise.

(value, index, obj) => unknown

find calls predicate once for each element of the array, in ascending order, until it finds one where predicate returns true. If such an element is found, findIndex immediately returns that element index. Otherwise, findIndex returns -1.

any

If provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.

number

Tuple3.findIndex


findLast<S>(predicate, thisArg?): undefined | S

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:29

Returns the value of the last element in the array where predicate is true, and undefined otherwise.

S extends number

(value, index, array) => value is S

findLast calls predicate once for each element of the array, in descending order, until it finds one where predicate returns true. If such an element is found, findLast immediately returns that element value. Otherwise, findLast returns undefined.

any

If provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.

undefined | S

Tuple3.findLast

findLast(predicate, thisArg?): undefined | number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:30

(value, index, array) => unknown

any

undefined | number

Tuple3.findLast


findLastIndex(predicate, thisArg?): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:41

Returns the index of the last element in the array where predicate is true, and -1 otherwise.

(value, index, array) => unknown

findLastIndex calls predicate once for each element of the array, in descending order, until it finds one where predicate returns true. If such an element is found, findLastIndex immediately returns that element index. Otherwise, findLastIndex returns -1.

any

If provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.

number

Tuple3.findLastIndex


flat<A, D>(this, depth?): FlatArray<A, D>[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2019.array.d.ts:75

Returns a new array with all sub-array elements concatenated into it recursively up to the specified depth.

A

D extends number = 1

A

D

The maximum recursion depth

FlatArray<A, D>[]

Tuple3.flat


flatMap<U, This>(callback, thisArg?): U[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2019.array.d.ts:64

Calls a defined callback function on each element of an array. Then, flattens the result into a new array. This is identical to a map followed by flat with depth 1.

U

This = undefined

(this, value, index, array) => U | readonly U[]

A function that accepts up to three arguments. The flatMap method calls the callback function one time for each element in the array.

This

An object to which the this keyword can refer in the callback function. If thisArg is omitted, undefined is used as the this value.

U[]

Tuple3.flatMap


forEach(callbackfn, thisArg?): void

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1457

Performs the specified action for each element in an array.

(value, index, array) => void

A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.

any

An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.

void

Tuple3.forEach


includes(searchElement, fromIndex?): boolean

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2016.array.include.d.ts:25

Determines whether an array includes a certain element, returning true or false as appropriate.

number

The element to search for.

number

The position in this array at which to begin searching for searchElement.

boolean

Tuple3.includes


indexOf(searchElement, fromIndex?): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1418

Returns the index of the first occurrence of a value in an array, or -1 if it is not present.

number

The value to locate in the array.

number

The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.

number

Tuple3.indexOf


join(separator?): string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1361

Adds all the elements of an array into a string, separated by the specified separator string.

string

A string used to separate one element of the array from the next in the resulting string. If omitted, the array elements are separated with a comma.

string

Tuple3.join


keys(): ArrayIterator<number>

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.iterable.d.ts:88

Returns an iterable of keys in the array

ArrayIterator<number>

Tuple3.keys


lastIndexOf(searchElement, fromIndex?): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1424

Returns the index of the last occurrence of a specified value in an array, or -1 if it is not present.

number

The value to locate in the array.

number

The array index at which to begin searching backward. If fromIndex is omitted, the search starts at the last index in the array.

number

Tuple3.lastIndexOf


map<U>(callbackfn, thisArg?): U[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1463

Calls a defined callback function on each element of an array, and returns an array that contains the results.

U

(value, index, array) => U

A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.

any

An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.

U[]

Tuple3.map


mul(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:57

number

v3u

vecInfixNotation.mul

mul(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:58

v3u

v3u

vecInfixNotation.mul

mul(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:59

never

v3u

vecInfixNotation.mul


pop(): undefined | number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1339

Removes the last element from an array and returns it. If the array is empty, undefined is returned and the array is not modified.

undefined | number

Tuple3.pop


push(…items): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1344

Appends new elements to the end of an array, and returns the new length of the array.

number[]

New elements to add to the array.

number

Tuple3.push


reduce(callbackfn): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1481

Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

(previousValue, currentValue, currentIndex, array) => number

A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.

number

Tuple3.reduce

reduce(callbackfn, initialValue): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1482

(previousValue, currentValue, currentIndex, array) => number

number

number

Tuple3.reduce

reduce<U>(callbackfn, initialValue): U

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1488

Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

U

(previousValue, currentValue, currentIndex, array) => U

A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.

U

If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.

U

Tuple3.reduce


reduceRight(callbackfn): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1494

Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

(previousValue, currentValue, currentIndex, array) => number

A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.

number

Tuple3.reduceRight

reduceRight(callbackfn, initialValue): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1495

(previousValue, currentValue, currentIndex, array) => number

number

number

Tuple3.reduceRight

reduceRight<U>(callbackfn, initialValue): U

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1501

Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.

U

(previousValue, currentValue, currentIndex, array) => U

A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.

U

If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.

U

Tuple3.reduceRight


reverse(): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1366

Reverses the elements in an array in place. This method mutates the array and returns a reference to the same array.

number[]

Tuple3.reverse


shift(): undefined | number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1371

Removes the first element from an array and returns it. If the array is empty, undefined is returned and the array is not modified.

undefined | number

Tuple3.shift


slice(start?, end?): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1381

Returns a copy of a section of an array. For both start and end, a negative index can be used to indicate an offset from the end of the array. For example, -2 refers to the second to last element of the array.

number

The beginning index of the specified portion of the array. If start is undefined, then the slice begins at index 0.

number

The end index of the specified portion of the array. This is exclusive of the element at the index ‘end’. If end is undefined, then the slice extends to the end of the array.

number[]

Tuple3.slice


some(predicate, thisArg?): boolean

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1451

Determines whether the specified callback function returns true for any element of an array.

(value, index, array) => unknown

A function that accepts up to three arguments. The some method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value true, or until the end of the array.

any

An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.

boolean

Tuple3.some


sort(compareFn?): this

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1392

Sorts an array in place. This method mutates the array and returns a reference to the same array.

(a, b) => number

Function used to determine the order of the elements. It is expected to return a negative value if the first argument is less than the second argument, zero if they’re equal, and a positive value otherwise. If omitted, the elements are sorted in ascending, UTF-16 code unit order.

[11,2,22,1].sort((a, b) => a - b)

this

Tuple3.sort


splice(start, deleteCount?): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1399

Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.

number

The zero-based location in the array from which to start removing elements.

number

The number of elements to remove.

number[]

An array containing the elements that were deleted.

Tuple3.splice

splice(start, deleteCount, …items): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1407

Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.

number

The zero-based location in the array from which to start removing elements.

number

The number of elements to remove.

number[]

Elements to insert into the array in place of the deleted elements.

number[]

An array containing the elements that were deleted.

Tuple3.splice


sub(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:54

number

v3u

vecInfixNotation.sub

sub(other): v3u

Defined in: packages/typegpu/src/data/wgslTypes.ts:55

v3u

v3u

vecInfixNotation.sub


toLocaleString(): string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1334

Returns a string representation of an array. The elements are converted to string using their toLocaleString methods.

string

Tuple3.toLocaleString

toLocaleString(locales, options?): string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.core.d.ts:64

string | string[]

NumberFormatOptions & DateTimeFormatOptions

string

Tuple3.toLocaleString


toReversed(): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:46

Returns a copy of an array with its elements reversed.

number[]

Tuple3.toReversed


toSorted(compareFn?): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:57

Returns a copy of an array with its elements sorted.

(a, b) => number

Function used to determine the order of the elements. It is expected to return a negative value if the first argument is less than the second argument, zero if they’re equal, and a positive value otherwise. If omitted, the elements are sorted in ascending, UTF-16 code unit order.

[11, 2, 22, 1].toSorted((a, b) => a - b) // [1, 2, 11, 22]

number[]

Tuple3.toSorted


toSpliced(start, deleteCount, …items): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:66

Copies an array and removes elements and, if necessary, inserts new elements in their place. Returns the copied array.

number

The zero-based location in the array from which to start removing elements.

number

The number of elements to remove.

number[]

Elements to insert into the copied array in place of the deleted elements.

number[]

The copied array.

Tuple3.toSpliced

toSpliced(start, deleteCount?): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:74

Copies an array and removes elements while returning the remaining elements.

number

The zero-based location in the array from which to start removing elements.

number

The number of elements to remove.

number[]

A copy of the original array with the remaining elements.

Tuple3.toSpliced


toString(): string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1330

Returns a string representation of an array.

string

Tuple3.toString


unshift(…items): number

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1412

Inserts new elements at the start of an array, and returns the new length of the array.

number[]

Elements to insert at the start of the array.

number

Tuple3.unshift


values(): ArrayIterator<number>

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2015.iterable.d.ts:93

Returns an iterable of values in the array

ArrayIterator<number>

Tuple3.values


with(index, value): number[]

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2023.array.d.ts:85

Copies an array, then overwrites the value at the provided index with the given value. If the index is negative, then it replaces from the end of the array.

number

The index of the value to overwrite. If the index is negative, then it replaces from the end of the array.

number

The value to write into the copied array.

number[]

The copied array with the updated value.

Tuple3.with