Support the Mesh Sequence Cache modifier (a.k.a. Alembic files)
This commit is contained in:
parent
6ac117cd37
commit
c718fb3a41
@ -46,6 +46,7 @@ eModifierType_WeightVGMix = 37
|
|||||||
eModifierType_WeightVGProximity = 38
|
eModifierType_WeightVGProximity = 38
|
||||||
eModifierType_Ocean = 39
|
eModifierType_Ocean = 39
|
||||||
eModifierType_MeshCache = 46
|
eModifierType_MeshCache = 46
|
||||||
|
eModifierType_MeshSequenceCache = 52
|
||||||
|
|
||||||
# DNA_particle_types.h
|
# DNA_particle_types.h
|
||||||
PART_DRAW_OB = 7
|
PART_DRAW_OB = 7
|
||||||
|
|||||||
@ -62,6 +62,17 @@ def modifier_filepath(ctx: ModifierContext, modifier: blendfile.BlendFileBlock,
|
|||||||
yield result.BlockUsage(modifier, path, path_full_field=field, block_name=block_name)
|
yield result.BlockUsage(modifier, path, path_full_field=field, block_name=block_name)
|
||||||
|
|
||||||
|
|
||||||
|
@mod_handler(cdefs.eModifierType_MeshSequenceCache)
|
||||||
|
def modifier_mesh_sequence_cache(ctx: ModifierContext, modifier: blendfile.BlendFileBlock,
|
||||||
|
block_name: bytes) -> typing.Iterator[result.BlockUsage]:
|
||||||
|
"""Yield the Alembic file(s) used by this modifier"""
|
||||||
|
cache_file = modifier.get_pointer(b'cache_file')
|
||||||
|
path, field = cache_file.get(b'filepath', return_field=True)
|
||||||
|
|
||||||
|
yield result.BlockUsage(cache_file, path, path_full_field=field,
|
||||||
|
block_name=b'%s.cache_file' % block_name)
|
||||||
|
|
||||||
|
|
||||||
@mod_handler(cdefs.eModifierType_Ocean)
|
@mod_handler(cdefs.eModifierType_Ocean)
|
||||||
def modifier_ocean(ctx: ModifierContext, modifier: blendfile.BlendFileBlock, block_name: bytes) \
|
def modifier_ocean(ctx: ModifierContext, modifier: blendfile.BlendFileBlock, block_name: bytes) \
|
||||||
-> typing.Iterator[result.BlockUsage]:
|
-> typing.Iterator[result.BlockUsage]:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user