trigger.actions.correctives =========================== .. py:module:: trigger.actions.correctives .. autoapi-nested-parse:: Action Module for Pose space deformations Attributes ---------- .. autoapisummary:: trigger.actions.correctives.ACTION_DATA trigger.actions.correctives.LOG Classes ------- .. autoapisummary:: trigger.actions.correctives.Correctives Module Contents --------------- .. py:class:: Correctives(**kwargs) Bases: :py:obj:`trigger.core.action.ActionCore` .. py:method:: action() Mandatory Method - Execute Action .. py:method:: connect_correctives(corrected_mesh, skinned_mesh, controller, target_matrix, psd_attr, discard_delta=True) :staticmethod: Extracts the deltas of the corrected mesh and connects it to the psd attribute Args: corrected_mesh: (String) Sculpted mesh skinned_mesh: (String) The mesh with the skinCluster controller: (String) Controller object which used to get into the sculpted position target_matrix: (tuple or list) target rotations of the the controller object psd_attr: (String) pose space deformer attribute which will initiall drive the corrected shape e.g. L_thumb.rotateX, angleExtract_loc.angleBetween discard_delta: (bool) if True, the delta shape which will be extracted by extractDeltas plugin will be deleted Returns: None .. py:method:: feed(action_data) Mandatory Method - Feeds the instance with the action data stored in actions session .. py:method:: save_action(file_path=None, *args, **kwargs) Mandatory Method - Save Action .. py:method:: ui(ctrl, layout, handler) Mandatory Method - UI setting definitions Args: ctrl: (model_ctrl) ctrl object instance of /ui/model_ctrl. Updates UI and Model layout: (QLayout) The layout object from the main ui. All setting widgets should be added to this layout handler: (actions_session) An instance of the actions_session. TRY NOT TO USE HANDLER UNLESS ABSOLUTELY NECESSARY Returns: None .. py:method:: vector_psd(driver_transform, controller, target_matrix, up_object, return_angle_attr=False, prefix='') :staticmethod: .. py:attribute:: action_data .. py:data:: ACTION_DATA .. py:data:: LOG example action data: ACTION_DATA = { "definitions": [ { "mode": 0, # 0 means Vector mode "driver_transform": "some_joint" "controller": "upper_arm_cont" "target_matrix": "some_rotation" "up_object": "some parent object of driver" "driver_axis": "This is not used with angle mode" "corrected_shape": "some_shape" "skinned_mesh": "awesome skinned mesh" }, { "mode": 1, # 1 means Single Acis mode "driver_transform": "some_joint" "controller": "upper_arm_cont" "target_matrix": "some_rotation" "up_object": "This is not used with single axis mode" "driver_axis": "X Y or Z axis" "corrected_shape": "some_shape" "skinned_mesh": "awesome skinned mesh" } ] }