from lnx.logicnode.lnx_nodes import * class DrawVideoNode(LnxLogicTreeNode): bl_idname = 'LNDrawVideoNode' bl_label = 'Draw Video' bl_description = '(JS ONLY Temp) Draws video from a canvas element' lnx_category = 'Draw' lnx_section = 'draw' lnx_version = 1 def lnx_init(self, context): self.add_input('LnxNodeSocketAction', 'Draw') self.add_input('LnxStringSocket', 'Video File') self.add_input('LnxColorSocket', 'Color', default_value=[1.0, 1.0, 1.0, 1.0]) self.add_input('LnxIntSocket', '0/1/2 = Left/Center/Right', default_value=0) self.add_input('LnxIntSocket', '0/1/2 = Top/Middle/Bottom', default_value=0) self.add_input('LnxFloatSocket', 'X') self.add_input('LnxFloatSocket', 'Y') self.add_input('LnxFloatSocket', 'Width') self.add_input('LnxFloatSocket', 'Height') self.add_input('LnxFloatSocket', 'Angle') self.add_output('LnxNodeSocketAction', 'Out') def register(): add_category('Draw', icon='GREASEPENCIL') DrawVideoNode.on_register()