2017-04-08 00:34:45 +02:00
|
|
|
from arm.logicnode.arm_nodes import *
|
|
|
|
|
2020-09-08 21:16:20 +02:00
|
|
|
class SeparateColorNode(ArmLogicTreeNode):
|
2020-10-05 19:55:56 +02:00
|
|
|
"""Splits the given color into RGB values."""
|
2017-04-08 00:34:45 +02:00
|
|
|
bl_idname = 'LNSeparateColorNode'
|
|
|
|
bl_label = 'Separate RGB'
|
2020-10-27 19:44:37 +01:00
|
|
|
arm_section = 'color'
|
2020-09-13 11:27:58 +02:00
|
|
|
arm_version = 1
|
2020-09-08 17:03:24 +02:00
|
|
|
|
2017-04-08 00:34:45 +02:00
|
|
|
def init(self, context):
|
2020-09-13 11:27:58 +02:00
|
|
|
super(SeparateColorNode, self).init(context)
|
2020-09-20 20:10:01 +02:00
|
|
|
self.add_input('NodeSocketColor', 'Color', default_value=[1.0, 1.0, 1.0, 1.0])
|
2020-09-08 21:49:02 +02:00
|
|
|
self.add_output('NodeSocketFloat', 'R')
|
|
|
|
self.add_output('NodeSocketFloat', 'G')
|
|
|
|
self.add_output('NodeSocketFloat', 'B')
|