Nail scissors, garden shears, sickle, scythe, long scythe, two-handed scythe and hammer remade from scratch in Blender in a grounded hand-painted style, with a metallic/smoothness mask so metal still shines. Materials come from ArtSource/materials_style.json; the builder now supports a mask texture and a faint paint glow. Blender sources, textures and previews live in ArtSource/Blender/stylized. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
53 lines
2.0 KiB
Python
53 lines
2.0 KiB
Python
"""Every painted tool in ArtSource/Blender/stylized side by side, for review in Blender.
|
|
|
|
blender -b --factory-startup --python ArtSource/Blender/scripts/gc_style_review.py
|
|
Writes ArtSource/Blender/stylized/Style_Tools_Review.blend (opens in Material Preview).
|
|
"""
|
|
import os
|
|
import bpy
|
|
from mathutils import Vector
|
|
|
|
HERE = os.path.dirname(os.path.abspath(__file__))
|
|
DIR = os.path.normpath(os.path.join(HERE, "..", "stylized"))
|
|
NAMES = ["SM_Tool_NailScissors", "SM_Tool_GardenShears", "SM_Tool_Sickle", "SM_Tool_Hammer",
|
|
"SM_Tool_Scythe", "SM_Tool_LongScythe", "SM_Tool_WideScythe"]
|
|
|
|
bpy.ops.wm.read_factory_settings(use_empty=True)
|
|
scene = bpy.context.scene
|
|
x = 0.0
|
|
for name in NAMES:
|
|
path = os.path.join(DIR, name + ".blend")
|
|
if not os.path.exists(path):
|
|
continue
|
|
with bpy.data.libraries.load(path, link=False) as (src, dst):
|
|
dst.objects = list(src.objects)
|
|
roots = []
|
|
for o in dst.objects:
|
|
if o is None or o.type not in {"MESH", "EMPTY"}:
|
|
continue
|
|
scene.collection.objects.link(o)
|
|
if o.parent is None:
|
|
roots.append(o)
|
|
# lay the tool out flat with a gap after the previous one
|
|
xs = [(o.matrix_world @ Vector(c)).x for o in dst.objects if o and o.type == "MESH" for c in o.bound_box]
|
|
width = (max(xs) - min(xs)) if xs else 0.3
|
|
for r in roots:
|
|
r.location.x += x - (min(xs) if xs else 0.0)
|
|
label = bpy.data.curves.new(name + "_label", "FONT")
|
|
label.body = name.replace("SM_Tool_", "")
|
|
label.size = 0.08
|
|
t = bpy.data.objects.new(name + "_label", label)
|
|
t.location = (x, -0.25, -0.4)
|
|
scene.collection.objects.link(t)
|
|
x += width + 0.35
|
|
|
|
for area_screen in bpy.data.screens:
|
|
for area in area_screen.areas:
|
|
if area.type == "VIEW_3D":
|
|
for sp in area.spaces:
|
|
if sp.type == "VIEW_3D":
|
|
sp.shading.type = "MATERIAL"
|
|
out = os.path.join(DIR, "Style_Tools_Review.blend")
|
|
bpy.ops.wm.save_as_mainfile(filepath=out, check_existing=False)
|
|
print("REVIEW", out)
|