picogl.backend.gl.legacy.view ============================= .. py:module:: picogl.backend.gl.legacy.view Classes ------- .. autoapisummary:: picogl.backend.gl.legacy.view.LegacyGLTranslation picogl.backend.gl.legacy.view.LegacyGLZoom picogl.backend.gl.legacy.view.LegacyGLRotation picogl.backend.gl.legacy.view.CameraPerspective picogl.backend.gl.legacy.view.LegacyGLViewTransform Module Contents --------------- .. py:class:: LegacyGLTranslation Translation Parameters .. py:attribute:: x :type: float :value: 0.0 .. py:attribute:: y :type: float :value: 0.0 .. py:attribute:: z :type: float :value: 0.0 .. py:method:: apply() .. py:method:: _apply_zoom(value: float = 0.01) .. py:class:: LegacyGLZoom Zoom parameters. .. py:attribute:: value :type: float :value: -5.0 def apply(self): self.apply_translation_and_zoom(self.translation, self.value) .. py:method:: apply_translation_and_zoom(translation, zoom) .. py:method:: rescale() .. py:class:: LegacyGLRotation .. py:attribute:: x :type: float :value: 0.0 .. py:attribute:: y :type: float :value: 0.0 .. py:attribute:: z :type: float :value: 0.0 .. py:method:: apply() .. py:method:: initialize() .. py:class:: CameraPerspective Represents parameters required to define a camera perspective. This class provides default values for the far clipping plane, near clipping plane, and field of view in the y-direction (fovy) for a perspective camera. These parameters can be used to set up a perspective projection for 3D rendering. .. py:attribute:: far :type: float :value: 100.0 .. py:attribute:: near :type: float :value: 0.1 .. py:attribute:: fovy :type: float :value: 45.0 .. py:class:: LegacyGLViewTransform Encapsulates legacy OpenGL view rotation, translation, and zoom. .. py:attribute:: rotation :type: LegacyGLRotation .. py:attribute:: translation :type: LegacyGLTranslation .. py:attribute:: zoom :type: LegacyGLZoom .. py:property:: rotation_x :type: float .. py:property:: rotation_y :type: float .. py:property:: translation_x :type: float .. py:property:: translation_y :type: float .. py:method:: apply() -> None Apply the view transform using the legacy OpenGL matrix stack. .. py:method:: reset() -> None Reset view transformation to defaults.