@babylonjs/viewer
Version:
The Babylon Viewer aims to simplify a specific but common Babylon.js use case: loading, viewing, and interacting with a 3D model.
60 lines (57 loc) • 2.51 kB
JavaScript
import { S as ShaderStore } from './index-MZPybX0H.esm.js';
import { b as bonesDeclarationWGSL } from './bonesDeclaration-PMvyqkeE.esm.js';
import { b as bakedVertexAnimationDeclarationWGSL, i as instancesVertexWGSL } from './instancesVertex-DMZ4QPzF.esm.js';
import { c as clipPlaneVertexDeclarationWGSL, a as clipPlaneVertexWGSL } from './clipPlaneVertex-DrcLG8k3.esm.js';
import { f as fogVertexDeclarationWGSL, a as fogVertexWGSL } from './fogVertex-jAzZJUX3.esm.js';
import { i as instancesDeclarationWGSL } from './instancesDeclaration-BNVwxGTw.esm.js';
import { b as bonesVertexWGSL } from './bonesVertex-CJuJ5VLw.esm.js';
import { b as bakedVertexAnimationWGSL } from './bakedVertexAnimation-v7FGdAXH.esm.js';
import { v as vertexColorMixingWGSL } from './vertexColorMixing-C_ggORv4.esm.js';
// Do not edit.
const name = "colorVertexShader";
const shader = `attribute position: vec3f;
attribute color: vec4f;
uniform view: mat4x4f;
uniform viewProjection: mat4x4f;
varying vColor: vec4f;
@vertex
fn main(input : VertexInputs)->FragmentInputs {
var colorUpdated: vec4f=vertexInputs.color;
var worldPos: vec4f=finalWorld* vec4f(vertexInputs.position,1.0);vertexOutputs.position=uniforms.viewProjection*worldPos;
}`;
// Sideeffect
if (!ShaderStore.ShadersStoreWGSL[name]) {
ShaderStore.ShadersStoreWGSL[name] = shader;
}
const includes = [bonesDeclarationWGSL, bakedVertexAnimationDeclarationWGSL, clipPlaneVertexDeclarationWGSL, fogVertexDeclarationWGSL, instancesDeclarationWGSL, instancesVertexWGSL, bonesVertexWGSL, bakedVertexAnimationWGSL, clipPlaneVertexWGSL, fogVertexWGSL, vertexColorMixingWGSL];
for (const inc of includes) {
if (!ShaderStore.IncludesShadersStoreWGSL[inc.name]) {
ShaderStore.IncludesShadersStoreWGSL[inc.name] = inc.shader;
}
}
/** @internal */
const colorVertexShaderWGSL = { name, shader };
export { colorVertexShaderWGSL };
//# sourceMappingURL=color.vertex-CN7ukM8n.esm.js.map