babylonjs.proceduralTextures.d.ts 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286
  1. declare module BABYLON {
  2. class WoodProceduralTexture extends ProceduralTexture {
  3. private _ampScale;
  4. private _woodColor;
  5. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  6. updateShaderUniforms(): void;
  7. ampScale: number;
  8. woodColor: Color3;
  9. /**
  10. * Serializes this wood procedural texture
  11. * @returns a serialized wood procedural texture object
  12. */
  13. serialize(): any;
  14. /**
  15. * Creates a Wood Procedural Texture from parsed wood procedural texture data
  16. * @param parsedTexture defines parsed texture data
  17. * @param scene defines the current scene
  18. * @param rootUrl defines the root URL containing wood procedural texture information
  19. * @returns a parsed Wood Procedural Texture
  20. */
  21. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): WoodProceduralTexture;
  22. }
  23. }
  24. declare module BABYLON {
  25. class FireProceduralTexture extends ProceduralTexture {
  26. private _time;
  27. private _speed;
  28. private _autoGenerateTime;
  29. private _fireColors;
  30. private _alphaThreshold;
  31. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  32. updateShaderUniforms(): void;
  33. render(useCameraPostProcess?: boolean): void;
  34. static readonly PurpleFireColors: Color3[];
  35. static readonly GreenFireColors: Color3[];
  36. static readonly RedFireColors: Color3[];
  37. static readonly BlueFireColors: Color3[];
  38. autoGenerateTime: boolean;
  39. fireColors: Color3[];
  40. time: number;
  41. speed: Vector2;
  42. alphaThreshold: number;
  43. /**
  44. * Serializes this fire procedural texture
  45. * @returns a serialized fire procedural texture object
  46. */
  47. serialize(): any;
  48. /**
  49. * Creates a Fire Procedural Texture from parsed fire procedural texture data
  50. * @param parsedTexture defines parsed texture data
  51. * @param scene defines the current scene
  52. * @param rootUrl defines the root URL containing fire procedural texture information
  53. * @returns a parsed Fire Procedural Texture
  54. */
  55. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): FireProceduralTexture;
  56. }
  57. }
  58. declare module BABYLON {
  59. class CloudProceduralTexture extends ProceduralTexture {
  60. private _skyColor;
  61. private _cloudColor;
  62. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  63. updateShaderUniforms(): void;
  64. skyColor: Color4;
  65. cloudColor: Color4;
  66. /**
  67. * Serializes this cloud procedural texture
  68. * @returns a serialized cloud procedural texture object
  69. */
  70. serialize(): any;
  71. /**
  72. * Creates a Cloud Procedural Texture from parsed cloud procedural texture data
  73. * @param parsedTexture defines parsed texture data
  74. * @param scene defines the current scene
  75. * @param rootUrl defines the root URL containing cloud procedural texture information
  76. * @returns a parsed Cloud Procedural Texture
  77. */
  78. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): CloudProceduralTexture;
  79. }
  80. }
  81. declare module BABYLON {
  82. class GrassProceduralTexture extends ProceduralTexture {
  83. private _grassColors;
  84. private _groundColor;
  85. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  86. updateShaderUniforms(): void;
  87. grassColors: Color3[];
  88. groundColor: Color3;
  89. /**
  90. * Serializes this grass procedural texture
  91. * @returns a serialized grass procedural texture object
  92. */
  93. serialize(): any;
  94. /**
  95. * Creates a Grass Procedural Texture from parsed grass procedural texture data
  96. * @param parsedTexture defines parsed texture data
  97. * @param scene defines the current scene
  98. * @param rootUrl defines the root URL containing grass procedural texture information
  99. * @returns a parsed Grass Procedural Texture
  100. */
  101. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): GrassProceduralTexture;
  102. }
  103. }
  104. declare module BABYLON {
  105. class RoadProceduralTexture extends ProceduralTexture {
  106. private _roadColor;
  107. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  108. updateShaderUniforms(): void;
  109. roadColor: Color3;
  110. /**
  111. * Serializes this road procedural texture
  112. * @returns a serialized road procedural texture object
  113. */
  114. serialize(): any;
  115. /**
  116. * Creates a Road Procedural Texture from parsed road procedural texture data
  117. * @param parsedTexture defines parsed texture data
  118. * @param scene defines the current scene
  119. * @param rootUrl defines the root URL containing road procedural texture information
  120. * @returns a parsed Road Procedural Texture
  121. */
  122. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): RoadProceduralTexture;
  123. }
  124. }
  125. declare module BABYLON {
  126. class BrickProceduralTexture extends ProceduralTexture {
  127. private _numberOfBricksHeight;
  128. private _numberOfBricksWidth;
  129. private _jointColor;
  130. private _brickColor;
  131. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  132. updateShaderUniforms(): void;
  133. numberOfBricksHeight: number;
  134. numberOfBricksWidth: number;
  135. jointColor: Color3;
  136. brickColor: Color3;
  137. /**
  138. * Serializes this brick procedural texture
  139. * @returns a serialized brick procedural texture object
  140. */
  141. serialize(): any;
  142. /**
  143. * Creates a Brick Procedural Texture from parsed brick procedural texture data
  144. * @param parsedTexture defines parsed texture data
  145. * @param scene defines the current scene
  146. * @param rootUrl defines the root URL containing brick procedural texture information
  147. * @returns a parsed Brick Procedural Texture
  148. */
  149. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): BrickProceduralTexture;
  150. }
  151. }
  152. declare module BABYLON {
  153. class MarbleProceduralTexture extends ProceduralTexture {
  154. private _numberOfTilesHeight;
  155. private _numberOfTilesWidth;
  156. private _amplitude;
  157. private _jointColor;
  158. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  159. updateShaderUniforms(): void;
  160. numberOfTilesHeight: number;
  161. amplitude: number;
  162. numberOfTilesWidth: number;
  163. jointColor: Color3;
  164. /**
  165. * Serializes this marble procedural texture
  166. * @returns a serialized marble procedural texture object
  167. */
  168. serialize(): any;
  169. /**
  170. * Creates a Marble Procedural Texture from parsed marble procedural texture data
  171. * @param parsedTexture defines parsed texture data
  172. * @param scene defines the current scene
  173. * @param rootUrl defines the root URL containing marble procedural texture information
  174. * @returns a parsed Marble Procedural Texture
  175. */
  176. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): MarbleProceduralTexture;
  177. }
  178. }
  179. declare module BABYLON {
  180. class StarfieldProceduralTexture extends ProceduralTexture {
  181. private _time;
  182. private _alpha;
  183. private _beta;
  184. private _zoom;
  185. private _formuparam;
  186. private _stepsize;
  187. private _tile;
  188. private _brightness;
  189. private _darkmatter;
  190. private _distfading;
  191. private _saturation;
  192. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  193. updateShaderUniforms(): void;
  194. time: number;
  195. alpha: number;
  196. beta: number;
  197. formuparam: number;
  198. stepsize: number;
  199. zoom: number;
  200. tile: number;
  201. brightness: number;
  202. darkmatter: number;
  203. distfading: number;
  204. saturation: number;
  205. /**
  206. * Serializes this starfield procedural texture
  207. * @returns a serialized starfield procedural texture object
  208. */
  209. serialize(): any;
  210. /**
  211. * Creates a Starfield Procedural Texture from parsed startfield procedural texture data
  212. * @param parsedTexture defines parsed texture data
  213. * @param scene defines the current scene
  214. * @param rootUrl defines the root URL containing startfield procedural texture information
  215. * @returns a parsed Starfield Procedural Texture
  216. */
  217. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): StarfieldProceduralTexture;
  218. }
  219. }
  220. declare module BABYLON {
  221. class NormalMapProceduralTexture extends ProceduralTexture {
  222. private _baseTexture;
  223. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  224. updateShaderUniforms(): void;
  225. render(useCameraPostProcess?: boolean): void;
  226. resize(size: any, generateMipMaps: any): void;
  227. baseTexture: Texture;
  228. /**
  229. * Serializes this normal map procedural texture
  230. * @returns a serialized normal map procedural texture object
  231. */
  232. serialize(): any;
  233. /**
  234. * Creates a Normal Map Procedural Texture from parsed normal map procedural texture data
  235. * @param parsedTexture defines parsed texture data
  236. * @param scene defines the current scene
  237. * @param rootUrl defines the root URL containing normal map procedural texture information
  238. * @returns a parsed Normal Map Procedural Texture
  239. */
  240. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): NormalMapProceduralTexture;
  241. }
  242. }
  243. declare module BABYLON {
  244. class PerlinNoiseProceduralTexture extends ProceduralTexture {
  245. time: number;
  246. timeScale: number;
  247. translationSpeed: number;
  248. private _currentTranslation;
  249. constructor(name: string, size: number, scene: Scene, fallbackTexture?: Texture, generateMipMaps?: boolean);
  250. updateShaderUniforms(): void;
  251. render(useCameraPostProcess?: boolean): void;
  252. resize(size: any, generateMipMaps: any): void;
  253. /**
  254. * Serializes this perlin noise procedural texture
  255. * @returns a serialized perlin noise procedural texture object
  256. */
  257. serialize(): any;
  258. /**
  259. * Creates a Perlin Noise Procedural Texture from parsed perlin noise procedural texture data
  260. * @param parsedTexture defines parsed texture data
  261. * @param scene defines the current scene
  262. * @param rootUrl defines the root URL containing perlin noise procedural texture information
  263. * @returns a parsed Perlin Noise Procedural Texture
  264. */
  265. static Parse(parsedTexture: any, scene: Scene, rootUrl: string): PerlinNoiseProceduralTexture;
  266. }
  267. }