# Class LineShading

TwinfinityPostProcess is the base class that can be used to extend classes for post-process effects.

#### Hierarchy (View Summary)

- TwinfinityPostProcess
  - LineShading

##### Index

### Constructors

constructor

### Properties

_postProcess
_screenWrite

### Accessors

affectedCameras
lineThickness

### Methods

attach
detach
initialize
updateLineThicknessUniform

## Constructors

### constructor

- new LineShading(lineThickness?: number, strength?: number): LineShading

  #### Parameters

  - lineThickness: number = 0.3

    Thickness of the lines, value between 0 and 1.

  - strength: number = 0.35

  #### Returns LineShading

  Overrides TwinfinityPostProcess.constructor

## Properties

### `Protected`_postProcess

_postProcess: undefined | PostProcess = undefined

Inherited from TwinfinityPostProcess._postProcess

### `Protected`_screenWrite

_screenWrite: boolean

## Accessors

### affectedCameras

- get affectedCameras(): Set<Camera>

  Returns a set of all the cameras this post-process effect is attached to.

  #### Returns Set<Camera>

  Inherited from TwinfinityPostProcess.affectedCameras

### lineThickness

- get lineThickness(): number

  Returns the current line thickness value.

  #### Returns number

- set lineThickness(thickness: number): void

  Sets the line thickness and updates the shader with the new value.

  #### Parameters

  - thickness: number

    Thickness of the lines, value between 0 and 1.

  #### Returns void

## Methods

### attach

- attach(camera: Camera): boolean

  Runs the initialize method if the post-process has not yet been initialized. Then attaches the post-process effect to the specified camera.

  #### Parameters

  - camera: Camera

    The camera to attach the post-process effect to.

  #### Returns boolean

  true if the post-process effect was successfully attached to the camera, otherwise false.

  Inherited from TwinfinityPostProcess.attach

### detach

- detach(camera: Camera): boolean

  Disables the post-process effect for the specified camera.

  #### Parameters

  - camera: Camera

    The camera to detach the post-process effect from.

  #### Returns boolean

  true if the post-process effect was successfully detached from the camera, otherwise false.

  Overrides TwinfinityPostProcess.detach

### `Protected` initialize

- initialize(camera: Camera): PostProcess

  Method for initializing this post-process effect before it gets attached to a camera. This gets called automatically from attach.

  #### Parameters

  - camera: Camera

    BabylonJS camera variable.

  #### Returns PostProcess

  Overrides TwinfinityPostProcess.initialize

### `Protected` updateLineThicknessUniform

- updateLineThicknessUniform(effect: Effect, thickness: number): void

  #### Parameters

  - effect: Effect
  - thickness: number

  #### Returns void