Created
August 18, 2015 08:23
-
-
Save zeffii/1a7d6800559f9ee902f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import bpy | |
# default 80 faces, all Tris | |
obj = bpy.data.objects['Icosphere'] | |
# note the range is 80 * 3 | |
flattened_list = [] | |
[flattened_list.extend([0.5, 0.3, 0.7]) for i in range(80*3)] | |
obj.data.vertex_colors[0].data.foreach_set("color", flattened_list) | |
obj.data.update() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment