# Auto-generated by nodebpy.assets.generate_asset_api — do not edit manually.
from typing import TYPE_CHECKING, Literal
from ...builder import (
    AssetCompositorGroup,
    BooleanSocket,
    BundledLibrary,
    ColorSocket,
    FloatSocket,
    IntegerSocket,
    MatrixSocket,
    MenuSocket,
    ObjectSocket,
    SocketAccessor,
    VectorSocket,
)
from ...types import (
    InputBoolean,
    InputColor,
    InputFloat,
    InputInteger,
    InputMatrix,
    InputMenu,
    InputObject,
    InputVector,
)


class ChromaticAberration(AssetCompositorGroup):
    """
    Chromatic Aberration

    Parameters
    ----------
    image : InputColor
        Image
    type : InputMenu | Literal["Offset", "Scale", "Directional Blur", "Lens Dispersion"]
        Different styles of aberrations
    axis : InputMenu | Literal["Vertical", "Horizontal"]
        Direction of the aberration effect
    factor : InputFloat
        The intensity of the aberration effect
    center : InputVector
        The position the transformations pivot around, in normalized coordinates. 0 means the lower left corner and 1 means the upper right corner of the image.
    samples : InputInteger
        The number of samples used to compute the blur. The more samples the smoother the result, at the expense of more compute time. The actual number of samples is two to the power of this input, so it increases exponentially.
    fit : InputBoolean
        Scale the image such that it fits entirely in the frame, leaving no empty spaces at the corners

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.type : MenuSocket
        Different styles of aberrations
    i.axis : MenuSocket
        Direction of the aberration effect
    i.factor : FloatSocket
        The intensity of the aberration effect
    i.center : VectorSocket
        The position the transformations pivot around, in normalized coordinates. 0 means the lower left corner and 1 means the upper right corner of the image.
    i.samples : IntegerSocket
        The number of samples used to compute the blur. The more samples the smoother the result, at the expense of more compute time. The actual number of samples is two to the power of this input, so it increases exponentially.
    i.fit : BooleanSocket
        Scale the image such that it fits entirely in the frame, leaving no empty spaces at the corners

    Outputs
    -------
    o.image : ColorSocket
        Image
    """

    _name = "Chromatic Aberration"
    _asset_name = "Chromatic Aberration"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        type: MenuSocket
        """Different styles of aberrations"""
        axis: MenuSocket
        """Direction of the aberration effect"""
        factor: FloatSocket
        """The intensity of the aberration effect"""
        center: VectorSocket
        """The position the transformations pivot around, in normalized coordinates. 0 means the lower left corner and 1 means the upper right corner of the image."""
        samples: IntegerSocket
        """The number of samples used to compute the blur. The more samples the smoother the result, at the expense of more compute time. The actual number of samples is two to the power of this input, so it increases exponentially."""
        fit: BooleanSocket
        """Scale the image such that it fits entirely in the frame, leaving no empty spaces at the corners"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        type: InputMenu
        | Literal["Offset", "Scale", "Directional Blur", "Lens Dispersion"] = "Scale",
        axis: InputMenu | Literal["Vertical", "Horizontal"] = "Horizontal",
        factor: InputFloat = 0.2,
        center: InputVector = None,
        samples: InputInteger = 3,
        fit: InputBoolean = False,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_6": type,
                "Socket_8": axis,
                "Socket_2": factor,
                "Socket_3": center,
                "Socket_4": samples,
                "Socket_7": fit,
            }
        )


class CombineCylindrical(AssetCompositorGroup):
    """
    Combine Cylindrical

    Parameters
    ----------
    r : InputFloat
        Radius - Length of the vector
    phi : InputFloat
        Azimuth - Angle around the up axis
    z : InputFloat
        Offset from the ground plane

    Inputs
    ------
    i.r : FloatSocket
        Radius - Length of the vector
    i.phi : FloatSocket
        Azimuth - Angle around the up axis
    i.z : FloatSocket
        Offset from the ground plane

    Outputs
    -------
    o.vector : VectorSocket
        Vector
    """

    _name = "Combine Cylindrical"
    _asset_name = "Combine Cylindrical"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        r: FloatSocket
        """Radius - Length of the vector"""
        phi: FloatSocket
        """Azimuth - Angle around the up axis"""
        z: FloatSocket
        """Offset from the ground plane"""

    class _Outputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        r: InputFloat = 0.0,
        phi: InputFloat = 0.0,
        z: InputFloat = 0.0,
    ):
        super().__init__(**{"Socket_1": r, "Socket_2": phi, "Socket_3": z})


class CombineSpherical(AssetCompositorGroup):
    """
    Combine Spherical

    Parameters
    ----------
    r : InputFloat
        Radius - Length of the vector
    phi : InputFloat
        Azimuth - Angle around the up axis
    theta : InputFloat
        Zenith - Angle from the ground plane

    Inputs
    ------
    i.r : FloatSocket
        Radius - Length of the vector
    i.phi : FloatSocket
        Azimuth - Angle around the up axis
    i.theta : FloatSocket
        Zenith - Angle from the ground plane

    Outputs
    -------
    o.vector : VectorSocket
        Vector
    """

    _name = "Combine Spherical"
    _asset_name = "Combine Spherical"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        r: FloatSocket
        """Radius - Length of the vector"""
        phi: FloatSocket
        """Azimuth - Angle around the up axis"""
        theta: FloatSocket
        """Zenith - Angle from the ground plane"""

    class _Outputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        r: InputFloat = 0.0,
        phi: InputFloat = 0.0,
        theta: InputFloat = 0.0,
    ):
        super().__init__(**{"Socket_1": r, "Socket_2": phi, "Socket_3": theta})


class FilmGrain(AssetCompositorGroup):
    """
    Simulates the noise and behavior of analog film. Author: Selman Vorhoff

    Parameters
    ----------
    input : InputColor
        Input
    factor : InputFloat
        Amount of mixing between the effect and original image
    preset : InputMenu | Literal["8 mm Caffenol", "8 mm Home Movie", "Super 8 mm", "16 mm Broadcast", "16 mm Indie Cinema", "35 mm Portra 400", "Super 35 mm", "70 mm Cinema", "Custom"]
        Preset
    film_gauge : InputMenu | Literal["8 mm", "16 mm", "35 mm", "70 mm"]
        Film Gauge
    style : InputMenu | Literal["Xpro Sharp", "Cinematic Gritty", "Home Movie", "Studio Broadcast", "Pro Photography", "Cinematic Soft", "Custom Style"]
        Style
    animated : InputBoolean
        Should the noise change frame to frame
    iso : InputInteger
        ISO
    softness : InputFloat
        Halation-style softening: edges "bleed" and become smoother, adds bloom and noise that is somewhat pattern-aware
    acutance : InputFloat
        Sharpens large details and adds a halo around objects
    coarseness : InputFloat
        Emulsion roughness, also adds grain clamping
    patchiness : InputFloat
        Smoothness of the film substrate. High values contribute to a stroboscope effect when animating.
    saturation : InputFloat
        Noise colorfulness
    luma_bias : InputFloat
        Luma bias
    texture_scale : InputFloat
        Texture Scale

    Inputs
    ------
    i.input : ColorSocket
        Input
    i.factor : FloatSocket
        Amount of mixing between the effect and original image
    i.preset : MenuSocket
        Preset
    i.film_gauge : MenuSocket
        Film Gauge
    i.style : MenuSocket
        Style
    i.animated : BooleanSocket
        Should the noise change frame to frame
    i.iso : IntegerSocket
        ISO
    i.softness : FloatSocket
        Halation-style softening: edges "bleed" and become smoother, adds bloom and noise that is somewhat pattern-aware
    i.acutance : FloatSocket
        Sharpens large details and adds a halo around objects
    i.coarseness : FloatSocket
        Emulsion roughness, also adds grain clamping
    i.patchiness : FloatSocket
        Smoothness of the film substrate. High values contribute to a stroboscope effect when animating.
    i.saturation : FloatSocket
        Noise colorfulness
    i.luma_bias : FloatSocket
        Luma bias
    i.texture_scale : FloatSocket
        Texture Scale

    Outputs
    -------
    o.result : ColorSocket
        Result
    """

    _name = "Film Grain"
    _asset_name = "Film Grain"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        input: ColorSocket
        """Input"""
        factor: FloatSocket
        """Amount of mixing between the effect and original image"""
        preset: MenuSocket
        """Preset"""
        film_gauge: MenuSocket
        """Film Gauge"""
        style: MenuSocket
        """Style"""
        animated: BooleanSocket
        """Should the noise change frame to frame"""
        iso: IntegerSocket
        """ISO"""
        softness: FloatSocket
        """Halation-style softening: edges "bleed" and become smoother, adds bloom and noise that is somewhat pattern-aware"""
        acutance: FloatSocket
        """Sharpens large details and adds a halo around objects"""
        coarseness: FloatSocket
        """Emulsion roughness, also adds grain clamping"""
        patchiness: FloatSocket
        """Smoothness of the film substrate. High values contribute to a stroboscope effect when animating."""
        saturation: FloatSocket
        """Noise colorfulness"""
        luma_bias: FloatSocket
        """Luma bias"""
        texture_scale: FloatSocket
        """Texture Scale"""

    class _Outputs(SocketAccessor):
        result: ColorSocket
        """Result"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        input: InputColor = None,
        factor: InputFloat = 1.0,
        preset: InputMenu
        | Literal[
            "8 mm Caffenol",
            "8 mm Home Movie",
            "Super 8 mm",
            "16 mm Broadcast",
            "16 mm Indie Cinema",
            "35 mm Portra 400",
            "Super 35 mm",
            "70 mm Cinema",
            "Custom",
        ] = "Super 8 mm",
        film_gauge: InputMenu | Literal["8 mm", "16 mm", "35 mm", "70 mm"] = "16 mm",
        style: InputMenu
        | Literal[
            "Xpro Sharp",
            "Cinematic Gritty",
            "Home Movie",
            "Studio Broadcast",
            "Pro Photography",
            "Cinematic Soft",
            "Custom Style",
        ] = "Studio Broadcast",
        animated: InputBoolean = False,
        iso: InputInteger = 400,
        softness: InputFloat = 0.5,
        acutance: InputFloat = 0.5,
        coarseness: InputFloat = 0.5,
        patchiness: InputFloat = 0.5,
        saturation: InputFloat = 0.5,
        luma_bias: InputFloat = 0.5,
        texture_scale: InputFloat = 0.5,
    ):
        super().__init__(
            **{
                "Socket_1": input,
                "Socket_7": factor,
                "Socket_64": preset,
                "Socket_46": film_gauge,
                "Socket_47": style,
                "Socket_10": animated,
                "Socket_56": iso,
                "Socket_52": softness,
                "Socket_70": acutance,
                "Socket_53": coarseness,
                "Socket_54": patchiness,
                "Socket_55": saturation,
                "Socket_65": luma_bias,
                "Socket_73": texture_scale,
            }
        )


class ProjectWithDepth(AssetCompositorGroup):
    """
    Project with Depth

    Parameters
    ----------
    normalized : InputVector
        Normalized
    depth : InputFloat
        Depth
    projection : InputMatrix
        Projection
    transform : InputMatrix
        Transform
    clip_start : InputFloat
        Clip Start
    clip_end : InputFloat
        Clip End

    Inputs
    ------
    i.normalized : VectorSocket
        Normalized
    i.depth : FloatSocket
        Depth
    i.projection : MatrixSocket
        Projection
    i.transform : MatrixSocket
        Transform
    i.clip_start : FloatSocket
        Clip Start
    i.clip_end : FloatSocket
        Clip End

    Outputs
    -------
    o.vector : VectorSocket
        Vector
    """

    _name = "Project with Depth"
    _asset_name = "Project with Depth"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        normalized: VectorSocket
        """Normalized"""
        depth: FloatSocket
        """Depth"""
        projection: MatrixSocket
        """Projection"""
        transform: MatrixSocket
        """Transform"""
        clip_start: FloatSocket
        """Clip Start"""
        clip_end: FloatSocket
        """Clip End"""

    class _Outputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        normalized: InputVector = None,
        depth: InputFloat = 1.0,
        projection: InputMatrix = None,
        transform: InputMatrix = None,
        clip_start: InputFloat = 0.1,
        clip_end: InputFloat = 100.0,
    ):
        super().__init__(
            **{
                "Socket_3": normalized,
                "Socket_4": depth,
                "Socket_5": projection,
                "Socket_6": transform,
                "Socket_1": clip_start,
                "Socket_2": clip_end,
            }
        )


class Retime(AssetCompositorGroup):
    """
    Retime

    Parameters
    ----------
    offset : InputInteger
        Offset to add to the current scene frame. Can also be negative.
    step : InputInteger
        Snap scene frame to increments
    speed : InputFloat
        Multiply the current scene frame by this factor
    cyclic : InputBoolean
        Restart from start frame when Cycle Length is reached
    cycle_length : InputInteger
        Number of frames to cycle through. Not affected by Speed.

    Inputs
    ------
    i.offset : IntegerSocket
        Offset to add to the current scene frame. Can also be negative.
    i.step : IntegerSocket
        Snap scene frame to increments
    i.speed : FloatSocket
        Multiply the current scene frame by this factor
    i.cyclic : BooleanSocket
        Restart from start frame when Cycle Length is reached
    i.cycle_length : IntegerSocket
        Number of frames to cycle through. Not affected by Speed.

    Outputs
    -------
    o.frame : IntegerSocket
        Frame
    """

    _name = "Retime"
    _asset_name = "Retime"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        offset: IntegerSocket
        """Offset to add to the current scene frame. Can also be negative."""
        step: IntegerSocket
        """Snap scene frame to increments"""
        speed: FloatSocket
        """Multiply the current scene frame by this factor"""
        cyclic: BooleanSocket
        """Restart from start frame when Cycle Length is reached"""
        cycle_length: IntegerSocket
        """Number of frames to cycle through. Not affected by Speed."""

    class _Outputs(SocketAccessor):
        frame: IntegerSocket
        """Frame"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        offset: InputInteger = 0,
        step: InputInteger = 1,
        speed: InputFloat = 1.0,
        cyclic: InputBoolean = False,
        cycle_length: InputInteger = 10,
    ):
        super().__init__(
            **{
                "Socket_4": offset,
                "Socket_13": step,
                "Socket_14": speed,
                "Socket_11": cyclic,
                "Socket_3": cycle_length,
            }
        )


class ScreenTo3DSpace(AssetCompositorGroup):
    """
    Convert coordinates from screen to world space

    Parameters
    ----------
    normalized : InputVector
        2D screen space coordinates in the [0, 1] range
    depth : InputFloat
        Depth from camera in scene units. Same as depth pass
    camera : InputObject
        The camera used for rendering the scene

    Inputs
    ------
    i.normalized : VectorSocket
        2D screen space coordinates in the [0, 1] range
    i.depth : FloatSocket
        Depth from camera in scene units. Same as depth pass
    i.camera : ObjectSocket
        The camera used for rendering the scene

    Outputs
    -------
    o.vector : VectorSocket
        Projected 3D vector in 3D space
    """

    _name = "Screen to 3D Space"
    _asset_name = "Screen to 3D Space"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        normalized: VectorSocket
        """2D screen space coordinates in the [0, 1] range"""
        depth: FloatSocket
        """Depth from camera in scene units. Same as depth pass"""
        camera: ObjectSocket
        """The camera used for rendering the scene"""

    class _Outputs(SocketAccessor):
        vector: VectorSocket
        """Projected 3D vector in 3D space"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        normalized: InputVector = None,
        depth: InputFloat = 0.0,
        camera: InputObject = None,
    ):
        super().__init__(
            **{"Socket_0": normalized, "Socket_3": depth, "Socket_1": camera}
        )


class SensorNoise(AssetCompositorGroup):
    """
    Sensor Noise

    Parameters
    ----------
    image : InputColor
        Image
    luminance_noise : InputFloat
        The amount of value-based noise
    chroma_noise : InputFloat
        The amount of color noise
    animated : InputBoolean
        Change noise on every frame

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.luminance_noise : FloatSocket
        The amount of value-based noise
    i.chroma_noise : FloatSocket
        The amount of color noise
    i.animated : BooleanSocket
        Change noise on every frame

    Outputs
    -------
    o.image : ColorSocket
        Image
    """

    _name = "Sensor Noise"
    _asset_name = "Sensor Noise"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        luminance_noise: FloatSocket
        """The amount of value-based noise"""
        chroma_noise: FloatSocket
        """The amount of color noise"""
        animated: BooleanSocket
        """Change noise on every frame"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        luminance_noise: InputFloat = 0.1,
        chroma_noise: InputFloat = 0.05,
        animated: InputBoolean = False,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_2": luminance_noise,
                "Socket_4": chroma_noise,
                "Socket_3": animated,
            }
        )


class SeparateCylindrical(AssetCompositorGroup):
    """
    Decompose into its cylindrical components

    Parameters
    ----------
    vector : InputVector
        Vector

    Inputs
    ------
    i.vector : VectorSocket
        Vector

    Outputs
    -------
    o.r : FloatSocket
        Radius - Length of the vector
    o.phi : FloatSocket
        Azimuth - Angle around the up axis
    o.z : FloatSocket
        Offset from the ground plane
    """

    _name = "Separate Cylindrical"
    _asset_name = "Separate Cylindrical"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""

    class _Outputs(SocketAccessor):
        r: FloatSocket
        """Radius - Length of the vector"""
        phi: FloatSocket
        """Azimuth - Angle around the up axis"""
        z: FloatSocket
        """Offset from the ground plane"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        vector: InputVector = None,
    ):
        super().__init__(**{"Socket_0": vector})


class SeparateSpherical(AssetCompositorGroup):
    """
    Decompose into its cylindrical components

    Parameters
    ----------
    vector : InputVector
        Vector

    Inputs
    ------
    i.vector : VectorSocket
        Vector

    Outputs
    -------
    o.r : FloatSocket
        Radius - Length of the vector
    o.phi : FloatSocket
        Azimuth - Angle around the up axis
    o.theta : FloatSocket
        Zenith - Angle from the ground plane
    """

    _name = "Separate Spherical"
    _asset_name = "Separate Spherical"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""

    class _Outputs(SocketAccessor):
        r: FloatSocket
        """Radius - Length of the vector"""
        phi: FloatSocket
        """Azimuth - Angle around the up axis"""
        theta: FloatSocket
        """Zenith - Angle from the ground plane"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        vector: InputVector = None,
    ):
        super().__init__(**{"Socket_0": vector})


class Sepia(AssetCompositorGroup):
    """
    Sepia

    Parameters
    ----------
    image : InputColor
        Image
    contrast : InputFloat
        Contrast
    tone : InputFloat
        Tone
    saturation : InputFloat
        Saturation

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.contrast : FloatSocket
        Contrast
    i.tone : FloatSocket
        Tone
    i.saturation : FloatSocket
        Saturation

    Outputs
    -------
    o.image : ColorSocket
        Image
    """

    _name = "Sepia"
    _asset_name = "Sepia"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        contrast: FloatSocket
        """Contrast"""
        tone: FloatSocket
        """Tone"""
        saturation: FloatSocket
        """Saturation"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        contrast: InputFloat = 0.0,
        tone: InputFloat = 0.5,
        saturation: InputFloat = 1.0,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_9": contrast,
                "Socket_6": tone,
                "Socket_7": saturation,
            }
        )


class SplitToning(AssetCompositorGroup):
    """
    Split Toning

    Parameters
    ----------
    image : InputColor
        Image
    highlights : InputColor
        Value of the first color input
    factor_highlights : InputFloat
        Factor Highlights
    shadows : InputColor
        Value of the second color input
    factor_shadows : InputFloat
        Factor Shadows
    balance : InputFloat
        How dominant highlights are compared to shadows
    smoothness : InputFloat
        Controls transition between highlights and shadows

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.highlights : ColorSocket
        Value of the first color input
    i.factor_highlights : FloatSocket
        Factor Highlights
    i.shadows : ColorSocket
        Value of the second color input
    i.factor_shadows : FloatSocket
        Factor Shadows
    i.balance : FloatSocket
        How dominant highlights are compared to shadows
    i.smoothness : FloatSocket
        Controls transition between highlights and shadows

    Outputs
    -------
    o.image : ColorSocket
        Image
    """

    _name = "Split Toning"
    _asset_name = "Split Toning"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        highlights: ColorSocket
        """Value of the first color input"""
        factor_highlights: FloatSocket
        """Factor Highlights"""
        shadows: ColorSocket
        """Value of the second color input"""
        factor_shadows: FloatSocket
        """Factor Shadows"""
        balance: FloatSocket
        """How dominant highlights are compared to shadows"""
        smoothness: FloatSocket
        """Controls transition between highlights and shadows"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        highlights: InputColor = None,
        factor_highlights: InputFloat = 0.5,
        shadows: InputColor = None,
        factor_shadows: InputFloat = 0.2,
        balance: InputFloat = 0.2,
        smoothness: InputFloat = 0.4,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_5": highlights,
                "Socket_4": factor_highlights,
                "Socket_6": shadows,
                "Socket_7": factor_shadows,
                "Socket_2": balance,
                "Socket_3": smoothness,
            }
        )


class TransformAndProject(AssetCompositorGroup):
    """
    Transform and Project

    Parameters
    ----------
    vector : InputVector
        Vector
    transform : InputMatrix
        Transform
    projection : InputMatrix
        Projection

    Inputs
    ------
    i.vector : VectorSocket
        Vector
    i.transform : MatrixSocket
        Transform
    i.projection : MatrixSocket
        Projection

    Outputs
    -------
    o.normalized : VectorSocket
        Normalized
    o.depth : FloatSocket
        Depth
    """

    _name = "Transform and Project"
    _asset_name = "Transform and Project"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        vector: VectorSocket
        """Vector"""
        transform: MatrixSocket
        """Transform"""
        projection: MatrixSocket
        """Projection"""

    class _Outputs(SocketAccessor):
        normalized: VectorSocket
        """Normalized"""
        depth: FloatSocket
        """Depth"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        vector: InputVector = None,
        transform: InputMatrix = None,
        projection: InputMatrix = None,
    ):
        super().__init__(
            **{"Socket_3": vector, "Socket_0": transform, "Socket_1": projection}
        )


class TuneImage(AssetCompositorGroup):
    """
    Tune Image

    Parameters
    ----------
    image : InputColor
        Image
    contrast : InputFloat
        Add more contrast relative to brightness
    color_boost : InputFloat
        Saturate the image
    clarity : InputFloat
        Low frequency contrast using an unsharp mask
    detail : InputFloat
        Higher frequency contrast using an unsharp mask
    sharpen : InputFloat
        The amount of diamond sharpening
    preserve_colors : InputBoolean
        Avoid color clipping by working in logarithmic space

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.contrast : FloatSocket
        Add more contrast relative to brightness
    i.color_boost : FloatSocket
        Saturate the image
    i.clarity : FloatSocket
        Low frequency contrast using an unsharp mask
    i.detail : FloatSocket
        Higher frequency contrast using an unsharp mask
    i.sharpen : FloatSocket
        The amount of diamond sharpening
    i.preserve_colors : BooleanSocket
        Avoid color clipping by working in logarithmic space

    Outputs
    -------
    o.image : ColorSocket
        Image
    """

    _name = "Tune Image"
    _asset_name = "Tune Image"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        contrast: FloatSocket
        """Add more contrast relative to brightness"""
        color_boost: FloatSocket
        """Saturate the image"""
        clarity: FloatSocket
        """Low frequency contrast using an unsharp mask"""
        detail: FloatSocket
        """Higher frequency contrast using an unsharp mask"""
        sharpen: FloatSocket
        """The amount of diamond sharpening"""
        preserve_colors: BooleanSocket
        """Avoid color clipping by working in logarithmic space"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        contrast: InputFloat = 0.0,
        color_boost: InputFloat = 0.0,
        clarity: InputFloat = 0.0,
        detail: InputFloat = 0.0,
        sharpen: InputFloat = 0.0,
        preserve_colors: InputBoolean = True,
    ):
        super().__init__(
            **{
                "Socket_0": image,
                "Socket_5": contrast,
                "Socket_2": color_boost,
                "Socket_3": clarity,
                "Socket_4": detail,
                "Socket_7": sharpen,
                "Socket_6": preserve_colors,
            }
        )


class UnsharpMask(AssetCompositorGroup):
    """
    Unsharp Mask

    Parameters
    ----------
    image : InputColor
        Image
    radius : InputFloat
        The pixel radius of the sharpening mask
    factor : InputFloat
        The amount of sharpening
    threshold : InputFloat
        Edge threshold

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.radius : FloatSocket
        The pixel radius of the sharpening mask
    i.factor : FloatSocket
        The amount of sharpening
    i.threshold : FloatSocket
        Edge threshold

    Outputs
    -------
    o.result : ColorSocket
        Result
    """

    _name = "Unsharp Mask"
    _asset_name = "Unsharp Mask"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        radius: FloatSocket
        """The pixel radius of the sharpening mask"""
        factor: FloatSocket
        """The amount of sharpening"""
        threshold: FloatSocket
        """Edge threshold"""

    class _Outputs(SocketAccessor):
        result: ColorSocket
        """Result"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        radius: InputFloat = 8.0,
        factor: InputFloat = 0.5,
        threshold: InputFloat = 0.0,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_2": radius,
                "Socket_3": factor,
                "Socket_4": threshold,
            }
        )


class Vignette(AssetCompositorGroup):
    """
    Vignette

    Parameters
    ----------
    image : InputColor
        Image
    factor : InputFloat
        Factor
    feather : InputFloat
        Smoothness of the transition between dark and bright regions
    corner_roundness : InputFloat
        Circularity of the effect
    scale : InputVector
        Relative size of area to be darkened
    offset : InputVector
        Relative translation of area to be darkened
    angle : InputFloat
        Rotation of the area to be darkened

    Inputs
    ------
    i.image : ColorSocket
        Image
    i.factor : FloatSocket
        Factor
    i.feather : FloatSocket
        Smoothness of the transition between dark and bright regions
    i.corner_roundness : FloatSocket
        Circularity of the effect
    i.scale : VectorSocket
        Relative size of area to be darkened
    i.offset : VectorSocket
        Relative translation of area to be darkened
    i.angle : FloatSocket
        Rotation of the area to be darkened

    Outputs
    -------
    o.image : ColorSocket
        Image
    o.mask : FloatSocket
        The region where the image will be darkened
    """

    _name = "Vignette"
    _asset_name = "Vignette"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        factor: FloatSocket
        """Factor"""
        feather: FloatSocket
        """Smoothness of the transition between dark and bright regions"""
        corner_roundness: FloatSocket
        """Circularity of the effect"""
        scale: VectorSocket
        """Relative size of area to be darkened"""
        offset: VectorSocket
        """Relative translation of area to be darkened"""
        angle: FloatSocket
        """Rotation of the area to be darkened"""

    class _Outputs(SocketAccessor):
        image: ColorSocket
        """Image"""
        mask: FloatSocket
        """The region where the image will be darkened"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        image: InputColor = None,
        factor: InputFloat = 1.0,
        feather: InputFloat = 0.4,
        corner_roundness: InputFloat = 1.0,
        scale: InputVector = None,
        offset: InputVector = None,
        angle: InputFloat = 0.0,
    ):
        super().__init__(
            **{
                "Socket_1": image,
                "Socket_10": factor,
                "Socket_4": feather,
                "Socket_3": corner_roundness,
                "Socket_8": scale,
                "Socket_6": offset,
                "Socket_7": angle,
            }
        )


class _3DToScreenSpace(AssetCompositorGroup):
    """
    Convert input coordinates to normalized camera space

    Parameters
    ----------
    vector : InputVector
        Input 3D coordinates in world space
    camera : InputObject
        The camera used for rendering the scene
    clamp_depth : InputBoolean
        Clamps depth to camera clipping range

    Inputs
    ------
    i.vector : VectorSocket
        Input 3D coordinates in world space
    i.camera : ObjectSocket
        The camera used for rendering the scene
    i.clamp_depth : BooleanSocket
        Clamps depth to camera clipping range

    Outputs
    -------
    o.normalized : VectorSocket
        2D coordinates in the [0, 1] range in screen space
    o.depth : FloatSocket
        Depth in scene units. Same as depth pass
    """

    _name = "3D to Screen Space"
    _asset_name = "3D to Screen Space"
    _library = BundledLibrary("compositing_nodes_essentials.blend")

    class _Inputs(SocketAccessor):
        vector: VectorSocket
        """Input 3D coordinates in world space"""
        camera: ObjectSocket
        """The camera used for rendering the scene"""
        clamp_depth: BooleanSocket
        """Clamps depth to camera clipping range"""

    class _Outputs(SocketAccessor):
        normalized: VectorSocket
        """2D coordinates in the [0, 1] range in screen space"""
        depth: FloatSocket
        """Depth in scene units. Same as depth pass"""

    if TYPE_CHECKING:

        @property
        def i(self) -> _Inputs: ...
        @property
        def o(self) -> _Outputs: ...

    def __init__(
        self,
        vector: InputVector = None,
        camera: InputObject = None,
        clamp_depth: InputBoolean = True,
    ):
        super().__init__(
            **{"Socket_4": vector, "Socket_0": camera, "Socket_6": clamp_depth}
        )


__all__ = (
    "ChromaticAberration",
    "CombineCylindrical",
    "CombineSpherical",
    "FilmGrain",
    "ProjectWithDepth",
    "Retime",
    "ScreenTo3DSpace",
    "SensorNoise",
    "SeparateCylindrical",
    "SeparateSpherical",
    "Sepia",
    "SplitToning",
    "TransformAndProject",
    "TuneImage",
    "UnsharpMask",
    "Vignette",
    "_3DToScreenSpace",
)
