From 89fc8bc9c8d5b4abbb83c080834d532cb38ded0a Mon Sep 17 00:00:00 2001 From: 989onan Date: Mon, 7 Jul 2025 13:14:00 -0400 Subject: [PATCH] Update visemes.py - fix viseme creation needing an armature (idk why it needed this) --- functions/visemes.py | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/functions/visemes.py b/functions/visemes.py index 889306a..a7365a8 100644 --- a/functions/visemes.py +++ b/functions/visemes.py @@ -8,11 +8,9 @@ from collections import OrderedDict from ..core.logging_setup import logger from ..core.translations import t from ..core.common import ( - get_active_armature, get_all_meshes, validate_mesh_for_pose ) -from ..core.armature_validation import validate_armature class VisemeCache: """Manages caching of generated viseme shape data for performance optimization""" @@ -140,12 +138,8 @@ class AvatarToolkit_OT_PreviewVisemes(Operator): props = context.scene.avatar_toolkit mesh_obj = bpy.data.objects.get(props.viseme_mesh) - # Validate armature and mesh - armature = get_active_armature(context) - if not armature: - return False - valid, _, _ = validate_armature(armature) - return valid and mesh_obj and mesh_obj.type == 'MESH' + # Validate mesh + return mesh_obj and mesh_obj.type == 'MESH' def execute(self, context: Context) -> Set[str]: props = context.scene.avatar_toolkit @@ -198,12 +192,8 @@ class AvatarToolkit_OT_CreateVisemes(Operator): props = context.scene.avatar_toolkit mesh_obj = bpy.data.objects.get(props.viseme_mesh) - # Validate armature and mesh - armature = get_active_armature(context) - if not armature: - return False - valid, _, _ = validate_armature(armature) - return valid and mesh_obj and mesh_obj.type == 'MESH' + # Validate mesh + return mesh_obj and mesh_obj.type == 'MESH' def execute(self, context: Context) -> Set[str]: props = context.scene.avatar_toolkit