# Generated by the protocol buffer compiler.  DO NOT EDIT!
# sources: blickfeld/percept_pipeline/data/coordinate_system.proto, blickfeld/percept_pipeline/data/health.proto, blickfeld/percept_pipeline/data/point_cloud_type.proto, blickfeld/percept_pipeline/data/state.proto
# plugin: python-betterproto
from dataclasses import dataclass

import blickfeld_qb2.betterproto as betterproto
import blickfeld_qb2.betterproto.lib.google.protobuf as betterproto_lib_google_protobuf

from ...base import data as __base_data__


class State(betterproto.Enum):
    """The states of pipeline"""

    STATE_UNSPECIFIED = 0
    """State field is not set"""

    STATE_STARTING = 1
    """Pipeline is getting started currently."""

    STATE_STABLE = 2
    """
    Pipeline is stable input and output of the pipeline are achieving the same
    frequency. Only very few frames are allowed to be dropped.
    """

    STATE_UNSTABLE = 3
    """
    Pipeline is unstable if the pipeline cannot process all frames of the data
    source and thus has to drop frames to keep up.
    """

    STATE_BROKEN = 4
    """
    Pipeline is broken if the pipeline does not generate the expected outputs,
    i.e. frames or state list at all. This can happen if the devices in the
    'data source' cannot be reached.
    """

    STATE_RESTARTING = 5
    """
    Pipeline is restarting if there is a larger configuration change, i.e. data
    source changed.
    """

    STATE_IDLE = 6
    """No processing is happening in the pipeline."""


class PointCloudType(betterproto.Enum):
    """The type of the point cloud"""

    POINT_CLOUD_TYPE_UNSPECIFIED = 0
    """The zero value that is not accepted"""

    POINT_CLOUD_TYPE_FULL = 1
    """
    Full point cloud (combined point cloud of all devices or unfiltered point
    cloud coming from one device)
    """

    POINT_CLOUD_TYPE_FOREGROUND = 2
    """Point cloud containing only foreground/points from moving objects"""


class CoordinateSystem(betterproto.Enum):
    """Specifies the coordinates system the data is expressed in"""

    COORDINATE_SYSTEM_UNSPECIFIED = 0
    """
    Coordinate system not specified. Not accepted neither within a request nor
    as response
    """

    COORDINATE_SYSTEM_LOCAL = 1
    """
    The data is expressed in the coordiante system of the data-source/device
    """

    COORDINATE_SYSTEM_TRANSFORMED = 2
    """The data is expressed in a map coordinate system"""


@dataclass(eq=False, repr=False)
class Health(betterproto.Message):
    """
    A health message that contains information about the pipeline status and
    the module itself.
    """

    state: "__base_data__.HealthState" = betterproto.enum_field(1)
    """High-level state of module."""

    state_reason: str = betterproto.string_field(2)
    """Reason for the given state. It is not set if state is STATE_OK."""

    pipeline_state: "State" = betterproto.enum_field(3)
    """
    Current state of the pipeline. It indicates if the pipeline is stable,
    unstable or broken.
    """
