Skip to content

Camera Data

cadwork.camera_data

camera_data

Source code in cadwork/camera_data.py
class camera_data:
    def get_position(self) -> point_3d:
        """get position
        Args:

        Returns:
            point_3d
        """

    def set_position(self, position: point_3d) -> None:
        """set position
        Args:
            position ( point_3d): position

        Returns:
            None
        """

    def get_target(self) -> point_3d:
        """get target
        Args:

        Returns:
            point_3d
        """

    def set_target(self, target: point_3d) -> None:
        """set target
        Args:
            target ( point_3d): target

        Returns:
            None
        """

    def get_up_vector(self) -> point_3d:
        """get up vector
        Args:

        Returns:
            point_3d
        """

    def set_up_vector(self, up_vector: point_3d) -> None:
        """set up vector
        Args:
            up_vector ( point_3d): up_vector

        Returns:
            None
        """

    def get_projection_type(self) -> projection_type:
        """get projection type
        Args:

        Returns:
            projection_type
        """

    def set_projection_type(self, projection_type: projection_type) -> None:
        """set projection type
        Args:
            projection_type ( projection_type): projection_type

        Returns:
            None
        """

    def get_field_width(self) -> float:
        """get field width
        Args:

        Returns:
            float
        """

    def set_field_width(self, field_width: float) -> None:
        """set field width
        Args:
            field_width ( float): field_width

        Returns:
            None
        """

    def get_field_height(self) -> float:
        """get field height
        Args:

        Returns:
            float
        """

    def set_field_height(self, field_height: float) -> None:
        """set field height
        Args:
            field_height ( float): field_height

        Returns:
            None
        """

    def get_field_of_view(self) -> float:
        """get field of view
        Args:

        Returns:
            float
        """

    def set_field_of_view(self, field_of_view: float) -> None:
        """set field of view
        Args:
            field_of_view ( float): field_of_view

        Returns:
            None
        """

get_field_height(self)

get field height

Returns:

Type Description
float

float

Source code in cadwork/camera_data.py
def get_field_height(self) -> float:
    """get field height
    Args:

    Returns:
        float
    """

get_field_of_view(self)

get field of view

Returns:

Type Description
float

float

Source code in cadwork/camera_data.py
def get_field_of_view(self) -> float:
    """get field of view
    Args:

    Returns:
        float
    """

get_field_width(self)

get field width

Returns:

Type Description
float

float

Source code in cadwork/camera_data.py
def get_field_width(self) -> float:
    """get field width
    Args:

    Returns:
        float
    """

get_position(self)

get position

Returns:

Type Description
<module 'cadwork.point_3d' from '/home/docs/checkouts/readthedocs.org/user_builds/cwapi3dpython/checkouts/latest/src/cadwork/point_3d.py'>

point_3d

Source code in cadwork/camera_data.py
def get_position(self) -> point_3d:
    """get position
    Args:

    Returns:
        point_3d
    """

get_projection_type(self)

get projection type

Returns:

Type Description
<module 'cadwork.projection_type' from '/home/docs/checkouts/readthedocs.org/user_builds/cwapi3dpython/checkouts/latest/src/cadwork/projection_type.py'>

projection_type

Source code in cadwork/camera_data.py
def get_projection_type(self) -> projection_type:
    """get projection type
    Args:

    Returns:
        projection_type
    """

get_target(self)

get target

Returns:

Type Description
<module 'cadwork.point_3d' from '/home/docs/checkouts/readthedocs.org/user_builds/cwapi3dpython/checkouts/latest/src/cadwork/point_3d.py'>

point_3d

Source code in cadwork/camera_data.py
def get_target(self) -> point_3d:
    """get target
    Args:

    Returns:
        point_3d
    """

get_up_vector(self)

get up vector

Returns:

Type Description
<module 'cadwork.point_3d' from '/home/docs/checkouts/readthedocs.org/user_builds/cwapi3dpython/checkouts/latest/src/cadwork/point_3d.py'>

point_3d

Source code in cadwork/camera_data.py
def get_up_vector(self) -> point_3d:
    """get up vector
    Args:

    Returns:
        point_3d
    """

set_field_height(self, field_height)

set field height

Parameters:

Name Type Description Default
field_height float

field_height

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_field_height(self, field_height: float) -> None:
    """set field height
    Args:
        field_height ( float): field_height

    Returns:
        None
    """

set_field_of_view(self, field_of_view)

set field of view

Parameters:

Name Type Description Default
field_of_view float

field_of_view

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_field_of_view(self, field_of_view: float) -> None:
    """set field of view
    Args:
        field_of_view ( float): field_of_view

    Returns:
        None
    """

set_field_width(self, field_width)

set field width

Parameters:

Name Type Description Default
field_width float

field_width

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_field_width(self, field_width: float) -> None:
    """set field width
    Args:
        field_width ( float): field_width

    Returns:
        None
    """

set_position(self, position)

set position

Parameters:

Name Type Description Default
position point_3d

position

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_position(self, position: point_3d) -> None:
    """set position
    Args:
        position ( point_3d): position

    Returns:
        None
    """

set_projection_type(self, projection_type)

set projection type

Parameters:

Name Type Description Default
projection_type projection_type

projection_type

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_projection_type(self, projection_type: projection_type) -> None:
    """set projection type
    Args:
        projection_type ( projection_type): projection_type

    Returns:
        None
    """

set_target(self, target)

set target

Parameters:

Name Type Description Default
target point_3d

target

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_target(self, target: point_3d) -> None:
    """set target
    Args:
        target ( point_3d): target

    Returns:
        None
    """

set_up_vector(self, up_vector)

set up vector

Parameters:

Name Type Description Default
up_vector point_3d

up_vector

required

Returns:

Type Description
None

None

Source code in cadwork/camera_data.py
def set_up_vector(self, up_vector: point_3d) -> None:
    """set up vector
    Args:
        up_vector ( point_3d): up_vector

    Returns:
        None
    """

cadwork.projection_type

projection_type (IntEnum)

projection type

Examples:

>>> cadwork.projection_type.Perspective
Perspective
Source code in cadwork/projection_type.py
@unique
class projection_type(IntEnum):
    """projection type

    Examples:
        >>> cadwork.projection_type.Perspective
        Perspective

    Args:
        Perspective = 1
        Orthographic = 2

    """
    Perspective = 1
    Orthographic = 2

    def __int__(self) -> int:
        return self.value

rendering: show_root_heading: false show_source: true

rendering: show_root_heading: false show_source: true