Asset Pipeline v2 #145

Closed
Nick Alberelli wants to merge 431 commits from (deleted):feature/asset-pipeline-v2 into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
2 changed files with 7 additions and 5 deletions
Showing only changes of commit 286c1d8188 - Show all commits

View File

@ -203,7 +203,7 @@ def transfer_data_add_entry(
return transfer_info return transfer_info
def get_transfer_data_by_name(transfer_data, td_type): def get_transfer_data_as_names(transfer_data, td_type):
return [ return [
transfer_info.name transfer_info.name
for transfer_info in transfer_data for transfer_info in transfer_data
@ -212,7 +212,9 @@ def get_transfer_data_by_name(transfer_data, td_type):
def transfer_info_clean(obj, list, td_type): def transfer_info_clean(obj, list, td_type):
transfer_data_list = get_transfer_data_by_name(obj.transfer_data_ownership, td_type) transfer_data_list = get_transfer_data_as_names(
obj.transfer_data_ownership, td_type
)
for item in list: for item in list:
if not asset_suffix.get_basename(item.name) in transfer_data_list: if not asset_suffix.get_basename(item.name) in transfer_data_list:
list.remove(item) list.remove(item)

View File

@ -277,7 +277,7 @@ def transfer_constraint(constraint_name, target_obj, source_obj):
def material_slot_clean(obj): def material_slot_clean(obj):
# Material slots cannot use generic transfer_info_clean() function # Material slots cannot use generic transfer_info_clean() function
context = util.get_stored_context() context = util.get_stored_context()
transfer_data_list = transfer_core.get_transfer_data_by_name( transfer_data_list = transfer_core.get_transfer_data_as_names(
obj.transfer_data_ownership, constants.MATERIAL_SLOT_KEY obj.transfer_data_ownership, constants.MATERIAL_SLOT_KEY
) )
for mat_slot in obj.material_slots: for mat_slot in obj.material_slots:
@ -397,7 +397,7 @@ def shape_keys_clean(obj):
context = util.get_stored_context() context = util.get_stored_context()
if obj.type != "MESH" or obj.data.shape_keys is None: if obj.type != "MESH" or obj.data.shape_keys is None:
return return
transfer_data_list = transfer_core.get_transfer_data_by_name( transfer_data_list = transfer_core.get_transfer_data_as_names(
obj.transfer_data_ownership, constants.SHAPE_KEY_KEY obj.transfer_data_ownership, constants.SHAPE_KEY_KEY
) )
for shape_key in obj.data.shape_keys.key_blocks: for shape_key in obj.data.shape_keys.key_blocks:
@ -512,7 +512,7 @@ def attribute_clean(obj):
if obj.type != "MESH": if obj.type != "MESH":
return return
attributes = attributes_get_editable(obj.data.attributes) attributes = attributes_get_editable(obj.data.attributes)
transfer_data_list = transfer_core.get_transfer_data_by_name( transfer_data_list = transfer_core.get_transfer_data_as_names(
obj.transfer_data_ownership, constants.ATTRIBUTE_KEY obj.transfer_data_ownership, constants.ATTRIBUTE_KEY
) )
for item in attributes: for item in attributes: