ソースを参照

Merge pull request #9739 from jasonsturges/doc/postprocesses

Post process documentation
Raanan Weber 4 年 前
コミット
b52310d817

+ 1 - 1
src/PostProcesses/RenderPipeline/Pipelines/defaultRenderingPipeline.ts

@@ -70,7 +70,7 @@ export class DefaultRenderingPipeline extends PostProcessRenderPipeline implemen
      */
     public depthOfField: DepthOfFieldEffect;
     /**
-     * The Fast Approximate Anti-Aliasing post process which attemps to remove aliasing from an image.
+     * The Fast Approximate Anti-Aliasing post process which attempts to remove aliasing from an image.
      */
     public fxaa: FxaaPostProcess;
     /**

+ 2 - 2
src/PostProcesses/RenderPipeline/Pipelines/lensRenderingPipeline.ts

@@ -294,7 +294,7 @@ export class LensRenderingPipeline extends PostProcessRenderPipeline {
      */
     public disableEdgeBlur() { this._edgeBlur = 0; }
     /**
-     * Sets the amout of grain
+     * Sets the amount of grain
      * @param amount Amount of grain
      */
     public setGrainAmount(amount: number) { this._grainAmount = amount; }
@@ -389,7 +389,7 @@ export class LensRenderingPipeline extends PostProcessRenderPipeline {
 
     /**
      * Removes the internal pipeline assets and detaches the pipeline from the scene cameras
-     * @param disableDepthRender If the scens depth rendering should be disabled (default: false)
+     * @param disableDepthRender If the scene's depth rendering should be disabled (default: false)
      */
     public dispose(disableDepthRender: boolean = false): void {
         this._scene.postProcessRenderPipelineManager.detachCamerasFromRenderPipeline(this._name, this._scene.cameras);

+ 1 - 1
src/PostProcesses/RenderPipeline/Pipelines/ssao2RenderingPipeline.ts

@@ -246,7 +246,7 @@ export class SSAO2RenderingPipeline extends PostProcessRenderPipeline {
     }
 
     /**
-     * Removes the internal pipeline assets and detatches the pipeline from the scene cameras
+     * Removes the internal pipeline assets and detaches the pipeline from the scene cameras
      */
     public dispose(disableGeometryBufferRenderer: boolean = false): void {
         for (var i = 0; i < this._scene.cameras.length; i++) {

+ 1 - 1
src/PostProcesses/RenderPipeline/Pipelines/ssaoRenderingPipeline.ts

@@ -154,7 +154,7 @@ export class SSAORenderingPipeline extends PostProcessRenderPipeline {
     }
 
     /**
-     * Removes the internal pipeline assets and detatches the pipeline from the scene cameras
+     * Removes the internal pipeline assets and detaches the pipeline from the scene cameras
      */
     public dispose(disableDepthRender: boolean = false): void {
         for (var i = 0; i < this._scene.cameras.length; i++) {

+ 7 - 7
src/PostProcesses/RenderPipeline/Pipelines/standardRenderingPipeline.ts

@@ -126,7 +126,7 @@ export class StandardRenderingPipeline extends PostProcessRenderPipeline impleme
      */
     public depthOfFieldPostProcess: Nullable<PostProcess> = null;
     /**
-     * The Fast Approximate Anti-Aliasing post process which attemps to remove aliasing from an image.
+     * The Fast Approximate Anti-Aliasing post process which attempts to remove aliasing from an image.
      */
     public fxaaPostProcess: Nullable<FxaaPostProcess> = null;
     /**
@@ -212,14 +212,14 @@ export class StandardRenderingPipeline extends PostProcessRenderPipeline impleme
     @serialize()
     public hdrIncreaseRate: number = 0.5;
     /**
-     * Gets wether or not the exposure of the overall pipeline should be automatically adjusted by the HDR post-process
+     * Gets whether or not the exposure of the overall pipeline should be automatically adjusted by the HDR post-process
      */
     @serialize()
     public get hdrAutoExposure(): boolean {
         return this._hdrAutoExposure;
     }
     /**
-     * Sets wether or not the exposure of the overall pipeline should be automatically adjusted by the HDR post-process
+     * Sets whether or not the exposure of the overall pipeline should be automatically adjusted by the HDR post-process
      */
     public set hdrAutoExposure(value: boolean) {
         this._hdrAutoExposure = value;
@@ -306,14 +306,14 @@ export class StandardRenderingPipeline extends PostProcessRenderPipeline impleme
     }
 
     /**
-     * Gets wether or not the motion blur post-process is object based or screen based.
+     * Gets whether or not the motion blur post-process is object based or screen based.
      */
     @serialize()
     public get objectBasedMotionBlur(): boolean {
         return this._isObjectBasedMotionBlur;
     }
     /**
-     * Sets wether or not the motion blur post-process should be object based or screen based
+     * Sets whether or not the motion blur post-process should be object based or screen based
      */
     public set objectBasedMotionBlur(value: boolean) {
         const shouldRebuild = this._isObjectBasedMotionBlur !== value;
@@ -384,7 +384,7 @@ export class StandardRenderingPipeline extends PostProcessRenderPipeline impleme
 
     /**
      * @ignore
-     * Specifies if the depth of field pipeline is enabed
+     * Specifies if the depth of field pipeline is enabled
      */
     @serialize()
     public get DepthOfFieldEnabled(): boolean {
@@ -402,7 +402,7 @@ export class StandardRenderingPipeline extends PostProcessRenderPipeline impleme
 
     /**
      * @ignore
-     * Specifies if the lens flare pipeline is enabed
+     * Specifies if the lens flare pipeline is enabled
      */
     @serialize()
     public get LensFlareEnabled(): boolean {

+ 5 - 5
src/PostProcesses/RenderPipeline/postProcessRenderEffect.ts

@@ -134,19 +134,19 @@ export class PostProcessRenderEffect {
 
     /**
      * Detaches the effect on cameras
-     * @param cameras The camera to detatch from.
+     * @param cameras The camera to detach from.
      * @hidden
      */
     public _detachCameras(cameras: Camera): void;
     /**
-     * Detatches the effect on cameras
-     * @param cameras The camera to detatch from.
+     * Detaches the effect on cameras
+     * @param cameras The camera to detach from.
      * @hidden
      */
     public _detachCameras(cameras: Camera[]): void;
     /**
-     * Detatches the effect on cameras
-     * @param cameras The camera to detatch from.
+     * Detaches the effect on cameras
+     * @param cameras The camera to detach from.
      * @hidden
      */
     public _detachCameras(cameras: any): void {

+ 2 - 2
src/PostProcesses/RenderPipeline/postProcessRenderPipelineManagerSceneComponent.ts

@@ -39,7 +39,7 @@ Object.defineProperty(Scene.prototype, "postProcessRenderPipelineManager", {
  */
 export class PostProcessRenderPipelineManagerSceneComponent implements ISceneComponent {
     /**
-     * The component name helpfull to identify the component in the list of scene components.
+     * The component name helpful to identify the component in the list of scene components.
      */
     public readonly name = SceneComponentConstants.NAME_POSTPROCESSRENDERPIPELINEMANAGER;
 
@@ -74,7 +74,7 @@ export class PostProcessRenderPipelineManagerSceneComponent implements ISceneCom
     }
 
     /**
-     * Disposes the component and the associated ressources
+     * Disposes the component and the associated resources
      */
     public dispose(): void {
         if (this.scene._postProcessRenderPipelineManager) {

+ 3 - 3
src/PostProcesses/blurPostProcess.ts

@@ -16,7 +16,7 @@ declare type Scene = import("../scene").Scene;
 
 /**
  * The Blur Post Process which blurs an image based on a kernel and direction.
- * Can be used twice in x and y directions to perform a guassian blur in two passes.
+ * Can be used twice in x and y directions to perform a gaussian blur in two passes.
  */
 export class BlurPostProcess extends PostProcess {
     @serialize("kernel")
@@ -54,7 +54,7 @@ export class BlurPostProcess extends PostProcess {
     }
 
     /**
-     * Sets wether or not the blur needs to unpack/repack floats
+     * Sets whether or not the blur needs to unpack/repack floats
      */
     public set packedFloat(v: boolean) {
         if (this._packedFloat === v) {
@@ -67,7 +67,7 @@ export class BlurPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether or not the blur is unpacking/repacking floats
+     * Gets whether or not the blur is unpacking/repacking floats
      */
     public get packedFloat(): boolean {
         return this._packedFloat;

+ 3 - 3
src/PostProcesses/chromaticAberrationPostProcess.ts

@@ -17,7 +17,7 @@ declare type Scene = import("../scene").Scene;
  */
 export class ChromaticAberrationPostProcess extends PostProcess {
     /**
-     * The amount of seperation of rgb channels (default: 30)
+     * The amount of separation of rgb channels (default: 30)
      */
     @serialize()
     aberrationAmount = 30;
@@ -29,13 +29,13 @@ export class ChromaticAberrationPostProcess extends PostProcess {
     radialIntensity = 0;
 
     /**
-     * The normilized direction in which the rgb channels should be seperated. If set to 0,0 radial direction will be used. (default: Vector2(0.707,0.707))
+     * The normalized direction in which the rgb channels should be separated. If set to 0,0 radial direction will be used. (default: Vector2(0.707,0.707))
      */
     @serialize()
     direction = new Vector2(0.707, 0.707);
 
     /**
-     * The center position where the radialIntensity should be around. [0.5,0.5 is center of screen, 1,1 is top right corder] (default: Vector2(0.5 ,0.5))
+     * The center position where the radialIntensity should be around. [0.5,0.5 is center of screen, 1,1 is top right corner] (default: Vector2(0.5 ,0.5))
      */
     @serialize()
     centerPosition = new Vector2(0.5, 0.5);

+ 2 - 2
src/PostProcesses/circleOfConfusionPostProcess.ts

@@ -16,12 +16,12 @@ import { serialize } from '../Misc/decorators';
  */
 export class CircleOfConfusionPostProcess extends PostProcess {
     /**
-     * Max lens size in scene units/1000 (eg. millimeter). Standard cameras are 50mm. (default: 50) The diamater of the resulting aperture can be computed by lensSize/fStop.
+     * Max lens size in scene units/1000 (eg. millimeter). Standard cameras are 50mm. (default: 50) The diameter of the resulting aperture can be computed by lensSize/fStop.
      */
     @serialize()
     public lensSize = 50;
     /**
-     * F-Stop of the effect's camera. The diamater of the resulting aperture can be computed by lensSize/fStop. (default: 1.4)
+     * F-Stop of the effect's camera. The diameter of the resulting aperture can be computed by lensSize/fStop. (default: 1.4)
      */
     @serialize()
     public fStop = 1.4;

+ 1 - 1
src/PostProcesses/depthOfFieldBlurPostProcess.ts

@@ -40,7 +40,7 @@ export class DepthOfFieldBlurPostProcess extends BlurPostProcess {
      * @param kernel The size of the kernel used to blur.
      * @param options The required width/height ratio to downsize to before computing the render pass.
      * @param camera The camera to apply the render pass to.
-     * @param circleOfConfusion The circle of confusion + depth map to be used to avoid blurring accross edges
+     * @param circleOfConfusion The circle of confusion + depth map to be used to avoid blurring across edges
      * @param imageToBlur The image to apply the blur to (default: Current rendered frame)
      * @param samplingMode The sampling mode to be used when computing the pass. (default: 0)
      * @param engine The engine which the post process will be applied. (default: current engine)

+ 2 - 2
src/PostProcesses/depthOfFieldEffect.ts

@@ -72,7 +72,7 @@ export class DepthOfFieldEffect extends PostProcessRenderEffect {
         return this._circleOfConfusion.focusDistance;
     }
     /**
-     * Max lens size in scene units/1000 (eg. millimeter). Standard cameras are 50mm. (default: 50) The diamater of the resulting aperture can be computed by lensSize/fStop.
+     * Max lens size in scene units/1000 (eg. millimeter). Standard cameras are 50mm. (default: 50) The diameter of the resulting aperture can be computed by lensSize/fStop.
      */
     public set lensSize(value: number) {
         this._circleOfConfusion.lensSize = value;
@@ -145,7 +145,7 @@ export class DepthOfFieldEffect extends PostProcessRenderEffect {
     }
 
     /**
-    * Get the current class name of the current effet
+    * Get the current class name of the current effect
     * @returns "DepthOfFieldEffect"
     */
     public getClassName(): string {

+ 10 - 10
src/PostProcesses/imageProcessingPostProcess.ts

@@ -126,13 +126,13 @@ export class ImageProcessingPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether the color curves effect is enabled.
+     * Gets whether the color curves effect is enabled.
      */
     public get colorCurvesEnabled(): boolean {
         return this.imageProcessingConfiguration.colorCurvesEnabled;
     }
     /**
-     * Sets wether the color curves effect is enabled.
+     * Sets whether the color curves effect is enabled.
      */
     public set colorCurvesEnabled(value: boolean) {
         this.imageProcessingConfiguration.colorCurvesEnabled = value;
@@ -152,13 +152,13 @@ export class ImageProcessingPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether the color grading effect is enabled.
+     * Gets whether the color grading effect is enabled.
      */
     public get colorGradingEnabled(): boolean {
         return this.imageProcessingConfiguration.colorGradingEnabled;
     }
     /**
-     * Gets wether the color grading effect is enabled.
+     * Gets whether the color grading effect is enabled.
      */
     public set colorGradingEnabled(value: boolean) {
         this.imageProcessingConfiguration.colorGradingEnabled = value;
@@ -178,13 +178,13 @@ export class ImageProcessingPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether tonemapping is enabled or not.
+     * Gets whether tonemapping is enabled or not.
      */
     public get toneMappingEnabled(): boolean {
         return this._imageProcessingConfiguration.toneMappingEnabled;
     }
     /**
-     * Sets wether tonemapping is enabled or not
+     * Sets whether tonemapping is enabled or not
      */
     public set toneMappingEnabled(value: boolean) {
         this._imageProcessingConfiguration.toneMappingEnabled = value;
@@ -310,13 +310,13 @@ export class ImageProcessingPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether the vignette effect is enabled.
+     * Gets whether the vignette effect is enabled.
      */
     public get vignetteEnabled(): boolean {
         return this.imageProcessingConfiguration.vignetteEnabled;
     }
     /**
-     * Sets wether the vignette effect is enabled.
+     * Sets whether the vignette effect is enabled.
      */
     public set vignetteEnabled(value: boolean) {
         this.imageProcessingConfiguration.vignetteEnabled = value;
@@ -325,13 +325,13 @@ export class ImageProcessingPostProcess extends PostProcess {
     @serialize()
     private _fromLinearSpace = true;
     /**
-     * Gets wether the input of the processing is in Gamma or Linear Space.
+     * Gets whether the input of the processing is in Gamma or Linear Space.
      */
     public get fromLinearSpace(): boolean {
         return this._fromLinearSpace;
     }
     /**
-     * Sets wether the input of the processing is in Gamma or Linear Space.
+     * Sets whether the input of the processing is in Gamma or Linear Space.
      */
     public set fromLinearSpace(value: boolean) {
         if (this._fromLinearSpace === value) {

+ 2 - 2
src/PostProcesses/motionBlurPostProcess.ts

@@ -57,7 +57,7 @@ export class MotionBlurPostProcess extends PostProcess {
     private _motionBlurSamples: number = 32;
 
     /**
-     * Gets wether or not the motion blur post-process is in object based mode.
+     * Gets whether or not the motion blur post-process is in object based mode.
      */
     @serialize()
     public get isObjectBased(): boolean {
@@ -65,7 +65,7 @@ export class MotionBlurPostProcess extends PostProcess {
     }
 
     /**
-     * Sets wether or not the motion blur post-process is in object based mode.
+     * Sets whether or not the motion blur post-process is in object based mode.
      */
     public set isObjectBased(value: boolean) {
         if (this._isObjectBased === value) {

+ 1 - 1
src/PostProcesses/postProcessManager.ts

@@ -72,7 +72,7 @@ export class PostProcessManager {
     // Methods
     /**
      * Prepares a frame to be run through a post process.
-     * @param sourceTexture The input texture to the post procesess. (default: null)
+     * @param sourceTexture The input texture to the post processes. (default: null)
      * @param postProcesses An array of post processes to be run. (default: null)
      * @returns True if the post processes were able to be run.
      * @hidden

+ 1 - 1
src/PostProcesses/refractionPostProcess.ts

@@ -12,7 +12,7 @@ import { SerializationHelper, serialize } from '../Misc/decorators';
 declare type Scene = import("../scene").Scene;
 
 /**
- * Post process which applies a refractin texture
+ * Post process which applies a refraction texture
  * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses#refraction
  */
 export class RefractionPostProcess extends PostProcess {

+ 2 - 2
src/PostProcesses/screenSpaceReflectionPostProcess.ts

@@ -150,7 +150,7 @@ export class ScreenSpaceReflectionPostProcess extends PostProcess {
     }
 
     /**
-     * Gets wether or not smoothing reflections is enabled.
+     * Gets whether or not smoothing reflections is enabled.
      * Enabling smoothing will require more GPU power and can generate a drop in FPS.
      */
     @serialize()
@@ -159,7 +159,7 @@ export class ScreenSpaceReflectionPostProcess extends PostProcess {
     }
 
     /**
-     * Sets wether or not smoothing reflections is enabled.
+     * Sets whether or not smoothing reflections is enabled.
      * Enabling smoothing will require more GPU power and can generate a drop in FPS.
      */
     public set enableSmoothReflections(enabled: boolean) {

+ 3 - 3
src/PostProcesses/stereoscopicInterlacePostProcess.ts

@@ -25,7 +25,7 @@ export class StereoscopicInterlacePostProcessI extends PostProcess {
     /**
      * Initializes a StereoscopicInterlacePostProcessI
      * @param name The name of the effect.
-     * @param rigCameras The rig cameras to be appled to the post process
+     * @param rigCameras The rig cameras to be applied to the post process
      * @param isStereoscopicHoriz If the rendered results are horizontal or vertical
      * @param isStereoscopicInterlaced If the rendered results are alternate line interlaced
      * @param samplingMode The sampling mode to be used when computing the pass. (default: 0)
@@ -65,8 +65,8 @@ export class StereoscopicInterlacePostProcess extends PostProcess {
     /**
      * Initializes a StereoscopicInterlacePostProcess
      * @param name The name of the effect.
-     * @param rigCameras The rig cameras to be appled to the post process
-     * @param isStereoscopicHoriz If the rendered results are horizontal or verticle
+     * @param rigCameras The rig cameras to be applied to the post process
+     * @param isStereoscopicHoriz If the rendered results are horizontal or vertical
      * @param samplingMode The sampling mode to be used when computing the pass. (default: 0)
      * @param engine The engine which the post process will be applied. (default: current engine)
      * @param reusable If the post process can be reused on the same frame. (default: false)

+ 1 - 1
src/PostProcesses/tonemapPostProcess.ts

@@ -42,7 +42,7 @@ export class TonemapPostProcess extends PostProcess {
      * @param textureFormat defines the texture format to use (BABYLON.Engine.TEXTURETYPE_UNSIGNED_INT by default)
      */
     constructor(name: string, private _operator: TonemappingOperator,
-        /** Defines the required exposure adjustement */
+        /** Defines the required exposure adjustment */
         public exposureAdjustment: number, camera: Camera, samplingMode: number = Constants.TEXTURE_BILINEAR_SAMPLINGMODE, engine?: Engine, textureFormat = Constants.TEXTURETYPE_UNSIGNED_INT) {
         super(name, "tonemap", ["_ExposureAdjustment"], null, 1.0, camera, samplingMode, engine, true, null, textureFormat);