サンプル
ShaderMaterial defaults forceSinglePass to true with built-in GLSL shaders, deep-clones Three math uniforms while nulling render-target textures on clone, and ignores index0AttributeName when passed via constructor parameters.
sha256:4542282f712d34732a99bc34abe42cedb9b96c5bff68536333598d1a47b9df4f
PUBLISHED
L3_CONTRACT_PASS
MIT-0
実行証拠
宣言環境と署名済み検証実行を分け、証明範囲を明確にします。
証拠の基準署名済みコントラクト合格
検証レシート1
検証レベルL3_CONTRACT_PASS
宣言された環境
- 実行コンテキスト
- node
- OS
- linux
- アーキテクチャ
- x64
- ランタイム
- node
- 言語
- node
- パッケージマネージャー
- npm
検証実行環境
- 実行コンテキスト
- node 22
- OS
- linux alpine · musl
- アーキテクチャ
- x64
- ランタイム
- node 22
- 言語
- javascript
- パッケージマネージャー
- npm
- 実行方式
- container · docker
CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-17
ケース
- ゴール
- ShaderMaterial defaults forceSinglePass to true with built-in GLSL shaders, deep-clones Three math uniforms while nulling render-target textures on clone, and ignores index0AttributeName when passed via constructor parameters. HOW
- パッケージ
-
three 0.185.1
- 環境
- node
- 作成日
- 2026-08-17T09:10:50Z
よくある思い込み
cloning a ShaderMaterial shallow-copies uniforms and passing index0AttributeName to the constructor assigns it to the material instance
このサンプルの作者が、ここで開発者やモデルが期待するであろうこととして記録したもの。下の契約が実際に実行されたものだ。
コントラクト
- ShaderMaterial deep-clones Three math uniforms so mutations to cloned Vector and Color values do not mutate the original material, while resetting render-target textures to null.
- ShaderMaterial initializes forceSinglePass to true, glslVersion to null, and provides default projection vertex and solid red fragment GLSL shaders.
- ShaderMaterial ignores index0AttributeName when provided in the constructor options object due to setValues treating undefined initial properties as invalid, requiring direct assignment on the instance.
- ShaderMaterial.toJSON serializes math uniforms into typed entries ('c', 'v2', 'v3', 'v4', 'm3', 'm4') that fromJSON restores to their respective Three math class instances.
- ShaderMaterial.clone creates independent uniform and defines objects but retains shared array references within defaultAttributeValues.
ファイル
- NOTES.md
- csx.json
- package-lock.json
- package.json
- test/contract.mjs
ソースアーティファクトをダウンロード (tar.gz)
オリジンシーダー
csx-seed
検証レシート
- node 22 · linux alpine/x64 · docker · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · node-typescript@1 · 2026-08-17 · ed25519:d91480838ac982c9