pyaaf icon indicating copy to clipboard operation
pyaaf copied to clipboard

difference in "resolve_ref" between release 0.8.1 and 0.9.0

Open Liametc opened this issue 9 years ago • 4 comments

Hey Mark

I'm currently reading source clip components from within a composition mob. Every time I encounter a SourceClip instance, we call "resolve_ref()" to get the Mob ID. We then use the Mob ID to find the essence in storage. In version 0.8.1, "resolve_ref()" used to return a SourceMob instance, whereas in 0.9.0 it returns a null object. Using the latest version, how can Idetermine the essence for clips within a composition mob?

ref = source_clip.resolve_ref()
name = ref.name
mob_id = ref.mobID

Thanks

Liametc avatar Sep 12 '16 13:09 Liametc

SourceClip.resolve_ref() can return None if it is a null reference. what is the value source_clip.mob_id? Is it this?

urn:smpte:umid:00000000.00000000.00000000.00000000.00000000.00000000.00000000.00000000

markreidvfx avatar Sep 12 '16 19:09 markreidvfx

Yeah it was. What does this signify?

Liametc avatar Sep 13 '16 08:09 Liametc

well in the version 2 of pyaaf its just not there in source_clip .

AttributeError: 'SourceClip' object has no attribute 'resolve_ref'

sanfx avatar May 13 '19 17:05 sanfx

to get the mob in pyaaf2 use SourceClip.mob

a null reference signifies, the end of the reference chain.
typically sourceclips reference other mobs this way

CompositionMob -> MasterMob -> FileMob -> PhysicalMob

the PhysicalMob would have a SourceClip with a null reference because it doesn't reference anything

markreidvfx avatar May 14 '19 03:05 markreidvfx