Skip to content

Commit

Permalink
missing files
Browse files Browse the repository at this point in the history
  • Loading branch information
keyboardspecialist committed Nov 22, 2024
1 parent 361312b commit 1991389
Show file tree
Hide file tree
Showing 8 changed files with 1,255 additions and 1 deletion.
2 changes: 1 addition & 1 deletion temp_wasm/cesiumjs-gsplat-utils/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
**/*.rs.bk
Cargo.lock
bin/
pkg/

wasm-pack.log
84 changes: 84 additions & 0 deletions temp_wasm/cesiumjs-gsplat-utils/pkg/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
<div align="center">

<h1><code>wasm-pack-template</code></h1>

<strong>A template for kick starting a Rust and WebAssembly project using <a href="https://github.com/rustwasm/wasm-pack">wasm-pack</a>.</strong>

<p>
<a href="https://travis-ci.org/rustwasm/wasm-pack-template"><img src="https://img.shields.io/travis/rustwasm/wasm-pack-template.svg?style=flat-square" alt="Build Status" /></a>
</p>

<h3>
<a href="https://rustwasm.github.io/docs/wasm-pack/tutorials/npm-browser-packages/index.html">Tutorial</a>
<span> | </span>
<a href="https://discordapp.com/channels/442252698964721669/443151097398296587">Chat</a>
</h3>

<sub>Built with 🦀🕸 by <a href="https://rustwasm.github.io/">The Rust and WebAssembly Working Group</a></sub>
</div>

## About

[**📚 Read this template tutorial! 📚**][template-docs]

This template is designed for compiling Rust libraries into WebAssembly and
publishing the resulting package to NPM.

Be sure to check out [other `wasm-pack` tutorials online][tutorials] for other
templates and usages of `wasm-pack`.

[tutorials]: https://rustwasm.github.io/docs/wasm-pack/tutorials/index.html
[template-docs]: https://rustwasm.github.io/docs/wasm-pack/tutorials/npm-browser-packages/index.html

## 🚴 Usage

### 🐑 Use `cargo generate` to Clone this Template

[Learn more about `cargo generate` here.](https://github.com/ashleygwilliams/cargo-generate)

```
cargo generate --git https://github.com/rustwasm/wasm-pack-template.git --name my-project
cd my-project
```

### 🛠️ Build with `wasm-pack build`

```
wasm-pack build
```

### 🔬 Test in Headless Browsers with `wasm-pack test`

```
wasm-pack test --headless --firefox
```

### 🎁 Publish to NPM with `wasm-pack publish`

```
wasm-pack publish
```

## 🔋 Batteries Included

* [`wasm-bindgen`](https://github.com/rustwasm/wasm-bindgen) for communicating
between WebAssembly and JavaScript.
* [`console_error_panic_hook`](https://github.com/rustwasm/console_error_panic_hook)
for logging panic messages to the developer console.
* `LICENSE-APACHE` and `LICENSE-MIT`: most Rust projects are licensed this way, so these are included for you

## License

Licensed under either of

* Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
* MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)

at your option.

### Contribution

Unless you explicitly state otherwise, any contribution intentionally
submitted for inclusion in the work by you, as defined in the Apache-2.0
license, shall be dual licensed as above, without any additional terms or
conditions.
164 changes: 164 additions & 0 deletions temp_wasm/cesiumjs-gsplat-utils/pkg/cesiumjs_gsplat_utils.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
/* tslint:disable */
/* eslint-disable */
/**
* @param {Float32Array} positions
* @param {Float32Array} scales
* @param {Float32Array} rots
* @param {Uint8Array} colors
* @param {number} count
* @returns {TextureData}
*/
export function generate_texture_from_attrs(positions: Float32Array, scales: Float32Array, rots: Float32Array, colors: Uint8Array, count: number): TextureData;
/**
* @param {GSplatData} data
*/
export function radix_sort_simd(data: GSplatData): void;
/**
* @param {Float32Array} positions
* @param {Float32Array} scales
* @param {Float32Array} rotations
* @param {Uint8Array} colors
* @param {Float32Array} model_view
* @param {number} count
* @returns {Array<any>}
*/
export function radix_sort_gaussians_attrs(positions: Float32Array, scales: Float32Array, rotations: Float32Array, colors: Uint8Array, model_view: Float32Array, count: number): Array<any>;
/**
* @param {Float32Array} positions
* @param {Float32Array} model_view
* @param {number} texture_width
* @param {number} count
* @returns {Uint32Array}
*/
export function radix_sort_gaussians_indexes(positions: Float32Array, model_view: Float32Array, texture_width: number, count: number): Uint32Array;
/**
* @param {Float32Array} positions
* @param {Float32Array} scales
* @param {Float32Array} rotations
* @param {Uint8Array} colors
* @param {number} count
* @returns {object}
*/
export function generate_splat_texture_from_attrs(positions: Float32Array, scales: Float32Array, rotations: Float32Array, colors: Uint8Array, count: number): object;
export class GSplatData {
free(): void;
/**
* @param {Float32Array} positions
* @param {Float32Array} scales
* @param {Float32Array} rotations
* @param {Uint8Array} colors
* @param {Float32Array} model_view
* @param {number} count
*/
constructor(positions: Float32Array, scales: Float32Array, rotations: Float32Array, colors: Uint8Array, model_view: Float32Array, count: number);
/**
* @param {Float32Array} positions
* @param {Float32Array} scales
* @param {Float32Array} rotations
* @param {Uint8Array} colors
* @param {Float32Array} model_view
* @param {number} count
* @returns {GSplatData}
*/
static fromFloat32Arrays(positions: Float32Array, scales: Float32Array, rotations: Float32Array, colors: Uint8Array, model_view: Float32Array, count: number): GSplatData;
/**
* @returns {Float32Array}
*/
getPositions(): Float32Array;
/**
* @returns {Float32Array}
*/
getScales(): Float32Array;
/**
* @returns {Float32Array}
*/
getRotations(): Float32Array;
/**
* @returns {Uint8Array}
*/
getColors(): Uint8Array;
}
export class GaussianSorter {
free(): void;
/**
* @param {number} max_count
*/
constructor(max_count: number);
/**
* @param {Uint8Array} memory_buffer
* @param {number} positions_offset
* @param {number} scales_offset
* @param {number} rotations_offset
* @param {number} colors_offset
* @param {Float32Array} model_view
* @param {number} count
*/
sortGaussians(memory_buffer: Uint8Array, positions_offset: number, scales_offset: number, rotations_offset: number, colors_offset: number, model_view: Float32Array, count: number): void;
}
export class TextureData {
free(): void;
/**
* @param {Uint32Array} data
* @param {number} width
* @param {number} height
* @returns {TextureData}
*/
static new(data: Uint32Array, width: number, height: number): TextureData;
readonly data: Uint32Array;
readonly height: number;
readonly width: number;
}

export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;

export interface InitOutput {
readonly memory: WebAssembly.Memory;
readonly __wbg_texturedata_free: (a: number, b: number) => void;
readonly texturedata_data: (a: number) => Array;
readonly texturedata_width: (a: number) => number;
readonly texturedata_height: (a: number) => number;
readonly texturedata_new: (a: number, b: number, c: number, d: number) => number;
readonly generate_texture_from_attrs: (a: number, b: number, c: number, d: number, e: number) => Array;
readonly __wbg_gsplatdata_free: (a: number, b: number) => void;
readonly gsplatdata_new: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number, k: number) => number;
readonly gsplatdata_fromFloat32Arrays: (a: number, b: number, c: number, d: number, e: number, f: number) => Array;
readonly gsplatdata_getPositions: (a: number) => number;
readonly gsplatdata_getScales: (a: number) => number;
readonly gsplatdata_getRotations: (a: number) => number;
readonly gsplatdata_getColors: (a: number) => number;
readonly radix_sort_simd: (a: number) => Array;
readonly radix_sort_gaussians_attrs: (a: number, b: number, c: number, d: number, e: number, f: number) => Array;
readonly radix_sort_gaussians_indexes: (a: number, b: number, c: number, d: number) => Array;
readonly __wbg_gaussiansorter_free: (a: number, b: number) => void;
readonly gaussiansorter_new: (a: number) => number;
readonly gaussiansorter_sortGaussians: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => Array;
readonly generate_splat_texture_from_attrs: (a: number, b: number, c: number, d: number, e: number) => Array;
readonly __wbindgen_export_0: WebAssembly.Table;
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
readonly __wbindgen_malloc: (a: number, b: number) => number;
readonly __externref_table_dealloc: (a: number) => void;
readonly __wbindgen_exn_store: (a: number) => void;
readonly __externref_table_alloc: () => number;
readonly __wbindgen_start: () => void;
}

export type SyncInitInput = BufferSource | WebAssembly.Module;
/**
* Instantiates the given `module`, which can either be bytes or
* a precompiled `WebAssembly.Module`.
*
* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
*
* @returns {InitOutput}
*/
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;

/**
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
* for everything else, calls `WebAssembly.instantiate` directly.
*
* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
*
* @returns {Promise<InitOutput>}
*/
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
Loading

0 comments on commit 1991389

Please sign in to comment.