blackAndWhitePostProcess.d.ts 1.7 KB

123456789101112131415161718192021222324252627282930313233343536
  1. import type { PostProcessOptions } from "./postProcess";
  2. import { PostProcess } from "./postProcess";
  3. import type { Camera } from "../Cameras/camera";
  4. import type { AbstractEngine } from "../Engines/abstractEngine";
  5. import "../Shaders/blackAndWhite.fragment";
  6. import type { Nullable } from "../types";
  7. import type { Scene } from "../scene";
  8. /**
  9. * Post process used to render in black and white
  10. */
  11. export declare class BlackAndWhitePostProcess extends PostProcess {
  12. /**
  13. * Linear about to convert he result to black and white (default: 1)
  14. */
  15. degree: number;
  16. /**
  17. * Gets a string identifying the name of the class
  18. * @returns "BlackAndWhitePostProcess" string
  19. */
  20. getClassName(): string;
  21. /**
  22. * Creates a black and white post process
  23. * @see https://doc.babylonjs.com/features/featuresDeepDive/postProcesses/usePostProcesses#black-and-white
  24. * @param name The name of the effect.
  25. * @param options The required width/height ratio to downsize to before computing the render pass.
  26. * @param camera The camera to apply the render pass to.
  27. * @param samplingMode The sampling mode to be used when computing the pass. (default: 0)
  28. * @param engine The engine which the post process will be applied. (default: current engine)
  29. * @param reusable If the post process can be reused on the same frame. (default: false)
  30. */
  31. constructor(name: string, options: number | PostProcessOptions, camera: Nullable<Camera>, samplingMode?: number, engine?: AbstractEngine, reusable?: boolean);
  32. /**
  33. * @internal
  34. */
  35. static _Parse(parsedPostProcess: any, targetCamera: Camera, scene: Scene, rootUrl: string): Nullable<BlackAndWhitePostProcess>;
  36. }