babylon.effect.d.ts 1.5 KB

12345678910111213141516171819202122232425262728293031323334
  1. /// <reference path="../babylon.d.ts" />
  2. declare module BABYLON {
  3. class Effect {
  4. name: string;
  5. defines: string;
  6. constructor(baseName: string, attributesNames: string[], uniformsNames: string[], samplers: WebGLUniformLocation[], engine: Engine, defines: string);
  7. isReady(): boolean;
  8. getProgram(): WebGLProgram;
  9. getAttribute(index: number): string;
  10. getAttributesNames(): string;
  11. getAttributesCount(): number;
  12. getUniformIndex(uniformName: string): number;
  13. getUniform(uniformName: string): string;
  14. getSamplers(): WebGLUniformLocation[];
  15. getCompilationError(): string;
  16. _prepareEffect(vertexSourceCode: string, fragmentSourceCode: string, attributeNames: string[], defines: string): void;
  17. setTexture(channel: string, texture: Texture): void;
  18. setMatrices(uniformName: string, matrices: Matrix[]): void;
  19. setMatrix(uniformName: string, matrix: Matrix): void;
  20. setBool(uniformName: string, val: boolean): void;
  21. setVector3(uniformName: string, val: Vector3): void;
  22. setFloat2(uniformName: string, x: number, y: number);
  23. setFloat3(uniformName: string, x: number, y: number, z: number);
  24. setFloat4(uniformName: string, x: number, y: number, z: number, w: number);
  25. setColor3(uniformName: string, color: Color3): void;
  26. setColor4(uniformName: string, color: Color4): void;
  27. static ShadersStore: Object;
  28. }
  29. }