Skip to content

Commit

Permalink
chore: fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
load1n9 committed Mar 8, 2023
1 parent fd76f3d commit fbdbbf5
Show file tree
Hide file tree
Showing 873 changed files with 80,737 additions and 19,802 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ deno run --unstable --allow-ffi <file>

Extensions:

- [Babylon](https://www.babylonjs.com/) (Use
`ext/babylon.ts` for an easy to use wrapper)
- [Babylon](https://www.babylonjs.com/) (Use `ext/babylon.ts` for an easy to use
wrapper)

## Maintainers

Expand Down
20 changes: 17 additions & 3 deletions api/ext/GL_3DFX_multisample.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
25 changes: 21 additions & 4 deletions api/ext/GL_3DFX_tbuffer.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down Expand Up @@ -78,5 +92,8 @@ export function TbufferMask3DFX(

/** Loads all OpenGL API function pointers. */
export function load(proc: (name: string) => Deno.PointerValue): void {
fn_glTbufferMask3DFX = new Deno.UnsafeFnPointer(proc("glTbufferMask3DFX")!, def_glTbufferMask3DFX);
fn_glTbufferMask3DFX = new Deno.UnsafeFnPointer(
proc("glTbufferMask3DFX")!,
def_glTbufferMask3DFX,
);
}
20 changes: 17 additions & 3 deletions api/ext/GL_3DFX_texture_compression_FXT1.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
20 changes: 17 additions & 3 deletions api/ext/GL_AMD_blend_minmax_factor.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
20 changes: 17 additions & 3 deletions api/ext/GL_AMD_compressed_3DC_texture.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
20 changes: 17 additions & 3 deletions api/ext/GL_AMD_compressed_ATC_texture.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
20 changes: 17 additions & 3 deletions api/ext/GL_AMD_conservative_depth.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
56 changes: 45 additions & 11 deletions api/ext/GL_AMD_debug_output.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down Expand Up @@ -82,7 +96,9 @@ export const def_glDebugMessageEnableAMD = {
result: "void",
} as const;

let fn_glDebugMessageEnableAMD!: Deno.UnsafeFnPointer<typeof def_glDebugMessageEnableAMD>;
let fn_glDebugMessageEnableAMD!: Deno.UnsafeFnPointer<
typeof def_glDebugMessageEnableAMD
>;

export function DebugMessageEnableAMD(
category: GLenum,
Expand All @@ -105,7 +121,9 @@ export const def_glDebugMessageInsertAMD = {
result: "void",
} as const;

let fn_glDebugMessageInsertAMD!: Deno.UnsafeFnPointer<typeof def_glDebugMessageInsertAMD>;
let fn_glDebugMessageInsertAMD!: Deno.UnsafeFnPointer<
typeof def_glDebugMessageInsertAMD
>;

export function DebugMessageInsertAMD(
category: GLenum,
Expand All @@ -128,7 +146,9 @@ export const def_glDebugMessageCallbackAMD = {
result: "void",
} as const;

let fn_glDebugMessageCallbackAMD!: Deno.UnsafeFnPointer<typeof def_glDebugMessageCallbackAMD>;
let fn_glDebugMessageCallbackAMD!: Deno.UnsafeFnPointer<
typeof def_glDebugMessageCallbackAMD
>;

export function DebugMessageCallbackAMD(
callback: GLDEBUGPROCAMD,
Expand All @@ -145,7 +165,9 @@ export const def_glGetDebugMessageLogAMD = {
result: "u32",
} as const;

let fn_glGetDebugMessageLogAMD!: Deno.UnsafeFnPointer<typeof def_glGetDebugMessageLogAMD>;
let fn_glGetDebugMessageLogAMD!: Deno.UnsafeFnPointer<
typeof def_glGetDebugMessageLogAMD
>;

export function GetDebugMessageLogAMD(
count: GLuint,
Expand All @@ -169,8 +191,20 @@ export function GetDebugMessageLogAMD(

/** Loads all OpenGL API function pointers. */
export function load(proc: (name: string) => Deno.PointerValue): void {
fn_glDebugMessageEnableAMD = new Deno.UnsafeFnPointer(proc("glDebugMessageEnableAMD")!, def_glDebugMessageEnableAMD);
fn_glDebugMessageInsertAMD = new Deno.UnsafeFnPointer(proc("glDebugMessageInsertAMD")!, def_glDebugMessageInsertAMD);
fn_glDebugMessageCallbackAMD = new Deno.UnsafeFnPointer(proc("glDebugMessageCallbackAMD")!, def_glDebugMessageCallbackAMD);
fn_glGetDebugMessageLogAMD = new Deno.UnsafeFnPointer(proc("glGetDebugMessageLogAMD")!, def_glGetDebugMessageLogAMD);
fn_glDebugMessageEnableAMD = new Deno.UnsafeFnPointer(
proc("glDebugMessageEnableAMD")!,
def_glDebugMessageEnableAMD,
);
fn_glDebugMessageInsertAMD = new Deno.UnsafeFnPointer(
proc("glDebugMessageInsertAMD")!,
def_glDebugMessageInsertAMD,
);
fn_glDebugMessageCallbackAMD = new Deno.UnsafeFnPointer(
proc("glDebugMessageCallbackAMD")!,
def_glDebugMessageCallbackAMD,
);
fn_glGetDebugMessageLogAMD = new Deno.UnsafeFnPointer(
proc("glGetDebugMessageLogAMD")!,
def_glGetDebugMessageLogAMD,
);
}
20 changes: 17 additions & 3 deletions api/ext/GL_AMD_depth_clamp_separate.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// This file is auto-generated. Do not edit.

/// Util
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array | Float64Array;
const isTypedArray = (arr: unknown) => arr instanceof Int8Array || arr instanceof Uint8Array || arr instanceof Int16Array || arr instanceof Uint16Array || arr instanceof Int32Array || arr instanceof Uint32Array || arr instanceof Float32Array || arr instanceof Float64Array;
export type TypedArray =
| Int8Array
| Uint8Array
| Int16Array
| Uint16Array
| Int32Array
| Uint32Array
| Float32Array
| Float64Array;
const isTypedArray = (arr: unknown) =>
arr instanceof Int8Array || arr instanceof Uint8Array ||
arr instanceof Int16Array || arr instanceof Uint16Array ||
arr instanceof Int32Array || arr instanceof Uint32Array ||
arr instanceof Float32Array || arr instanceof Float64Array;
export type Buffer = TypedArray | ArrayBuffer | null | Deno.PointerValue;

export function bufferToFFI(buf: Buffer): Uint8Array | null {
Expand All @@ -12,7 +24,9 @@ export function bufferToFFI(buf: Buffer): Uint8Array | null {
} else if (isTypedArray(buf)) {
return new Uint8Array((buf as TypedArray).buffer);
} else {
return new Uint8Array(Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1));
return new Uint8Array(
Deno.UnsafePointerView.getArrayBuffer((buf as Deno.PointerValue)!, 1),
);
}
}

Expand Down
Loading

0 comments on commit fbdbbf5

Please sign in to comment.