Hi everyone
I am coding a personal add-on that can control some color in 3D view without open shader editor. And I just saw someone suggest use template for color ramp like:
layout.template_color_ramp(bpy.data.worlds["World"].node_tree.nodes["Sky Color"], "color_ramp", expand=True)
Its work, then I try to use color picker like:
layout.template_color_picker(bpy.data.scenes["Scene"].eevee.bloom_color, "color_picker", expand=False)
and got a error:
UILayout.template_color_picker(): error with argument 1, "data" - Function.data expected a AnyType type, not Color
Is there any way to use number input (float, int) and color picker as template that point directly to the available data? The document dont have any example and I cant find any example on internet. With this way its will shorten the code and make it more clearly.
doc link: https://docs.blender.org/api/current/bpy.types.UILayout.html
Thank you for your support!