Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on exportImages
- mPath = _movie.path
- savePath = "your_path_here" --replace this with the folder you want to export to
- sx = xtra("SharpExport").new()
- if objectP(sx) = 0 then
- alert "SharpExport initialization failed"
- exit
- end if
- repeat with n = 2 to the number of castLibs
- nMembers = castLib(n).member.count
- cFileName = castLib(n).name
- repeat with m = 1 to nMembers
- tMember = member(m, n)
- if tMember.type = #bitmap then
- tName = tMember.name
- tNumS = string(m)
- mNumS = string(n)
- OK = sx.exportBMP(tMember, savePath & "\" & cFileName & "-" & tNumS & ".bmp")
- if OK <> 0 then put "Export msg code:", OK, n, m
- end if
- end repeat
- end repeat
- put "Done..."
- end
- on exportAudio
- mPath = _movie.path
- savePath = "your_path_here" --replace this with the folder you want to export to
- repeat with n = 2 to the number of castLibs
- nMembers = castLib(n).member.count
- cFileName = castLib(n).name
- repeat with m = 1 to nMembers
- tMember = member(m, n)
- if tMember.type = #sound then
- tName = tMember.name
- if tName = EMPTY then tName = string(m)
- tNumS = string(m)
- mNumS = string(n)
- OK = axLoadSound(tNumS, "member", tMember)
- if OK <> 0 then put "axLoadSound failed:", OK, n, m
- OK = axConvertToFile(tNumS, savePath & "\" & cFileName & "-" & tNumS & ".wav", "WAVE")
- if OK <> 0 then put "Export msg code:", OK, n, m
- OK = axRemoveSound(tNumS)
- end if
- end repeat
- end repeat
- put "Done..."
- end
- --end of code
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement