Class ClippingPrimitive
An abstract primitive component to animate and visualize a clipping primitive that can be
used to drive per pixel based clipping.
Inheritance
ClippingPrimitive
Assembly: cs.temp.dll.dll
public abstract class ClippingPrimitive : MonoBehaviour
Fields
Declaration
protected List<Material> allocatedMaterials
Field Value
Type |
Description |
List<Material> |
|
Declaration
protected ClippingPrimitive.Side clippingSide
Field Value
Declaration
protected MaterialPropertyBlock materialPropertyBlock
Field Value
Type |
Description |
MaterialPropertyBlock |
|
Declaration
protected Dictionary<Material, bool> modifiedMaterials
Field Value
Type |
Description |
Dictionary<Material, Boolean> |
|
Declaration
protected List<Renderer> renderers
Field Value
Type |
Description |
List<Renderer> |
|
Properties
The renderer(s) that should be affected by the primitive.
Declaration
public ClippingPrimitive.Side ClippingSide { get; set; }
Property Value
Declaration
protected abstract string ClippingSideProperty { get; }
Property Value
Declaration
protected abstract string Keyword { get; }
Property Value
Declaration
public bool UseOnPreRender { get; set; }
Property Value
Methods
Declaration
public void AddRenderer(Renderer _renderer)
Parameters
Type |
Name |
Description |
Renderer |
_renderer |
|
Declaration
protected Material GetMaterial(Renderer _renderer, bool trackAllocations = true)
Parameters
Type |
Name |
Description |
Renderer |
_renderer |
|
Boolean |
trackAllocations |
|
Returns
Type |
Description |
Material |
|
Declaration
protected virtual void Initialize()
Declaration
protected void LateUpdate()
Declaration
protected void OnCameraPreRender(CameraEventRouter router)
Parameters
Declaration
protected void OnDestroy()
Declaration
protected void OnDisable()
Declaration
protected void OnEnable()
Declaration
protected void OnValidate()
Declaration
public void RemoveRenderer(Renderer _renderer)
Parameters
Type |
Name |
Description |
Renderer |
_renderer |
|
Declaration
protected void RestoreUnassignedMaterials()
Declaration
Declaration
protected void ToggleClippingFeature(Material material, bool keywordOn)
Parameters
Type |
Name |
Description |
Material |
material |
|
Boolean |
keywordOn |
|
Declaration
protected void ToggleClippingFeature(bool keywordOn)
Parameters
Type |
Name |
Description |
Boolean |
keywordOn |
|
Declaration
protected virtual void UpdateRenderers()
Declaration
protected abstract void UpdateShaderProperties(MaterialPropertyBlock materialPropertyBlock)
Parameters
Type |
Name |
Description |
MaterialPropertyBlock |
materialPropertyBlock |
|