"Impossibile aprire" quando si salvano i video combinati in QuickTime Player

2

Ho diverse centinaia di video suddivisi in dieci segmenti di 2 minuti, quindi eseguo un AppleScript per combinarli con QuickTime Player 10.4. Il modo in cui funziona è incollando tutte le parti in un filmato QuickTime (in una singola finestra), quindi il comando di tasti dello script + W per chiuderlo. Prima che si chiuda, un "Vuoi salvare prima di chiudere?" appare la finestra di dialogo, e lo script riempie il titolo desiderato e preme Salva.

Generalmente lo script funziona, ma a volte ricevo un messaggio di errore da QuickTime che dice "Impossibile aprire" dopo che la barra di salvataggio è già arrivata alla fine. Quando ciò accade, non riesco a salvare il video combinato, anche se provo di nuovo con una destinazione diversa o passando attraverso il menu di esportazione. (Quando si tenta di esportare dopo che questo si verifica, viene visualizzato l'errore "Impossibile aprire questo supporto potrebbe essere danneggiato.")

È stata posta una domanda sull'incontro di un errore simile, " non può aprire "quando provi a salvare la registrazione dello schermo nel player quicktime , e questa era la risposta migliore:

Sounds like a permissions problem. If it’s a bug I suspect it will be fixed in a future macOS update. Not much help, I know.

Until then, you have to peek behind the curtain:

  1. Unsaved recordings are stored at ~/Library/Containers/com.apple.QuickTimePlayerX/Data/Library/Autosave Information/

  2. The file will be called Unsaved QuickTime Player Document.qtpxcomposition, or similar

  3. Show Package Contents on that file

  4. Inside is Screen Recording.mov which you can copy and keep

Sfortunatamente, questo non ha funzionato per me. Il contenuto del pacchetto del file .qtpxcomposition non contiene un file .mov. Contiene solo il file "index.qtpx".

In ~ / Library / Containers / com.apple.QuickTimePlayerX / Data / Library / Autosave Information /, Ho i seguenti file:

  • "com.apple.QuickTimePlayerX.plist"
  • "Documenta non disponibile QuickTime Player document.qtpx"

Posso trascinare il file .qtpxcomposition in un'altra cartella, ma rimane solo 14 KB e QuickTime non può ancora salvarlo o esportarlo.

I video che sto combinando sono memorizzati su un disco rigido esterno e li sto salvando su un altro disco rigido esterno. Mi sono assicurato nelle mie Impostazioni di sistema che i dischi rigidi non vanno a dormire quando sono inattivi. Quindi, tutto questo è per dire che sono perplesso sul perché questo errore si sta verificando, e apprezzerei molto qualsiasi feedback.

Ecco il mio AppleScript completo, anche se non penso che abbia qualcosa a che fare con l'errore:

on run {input, parameters}

    --record subfolder list
    set subfolderList to input

    tell application "Finder"
        --get number of folders
        set numFolders to count items of input

    end tell

    --repeat for all subfolders
    repeat with n from 56 to numFolders

        tell application "System Events"
            --wait until current video finishes saving
            repeat until (not (exists window "Untitled" of application "QuickTime Player"))
                delay 5
            end repeat
        end tell

        --display warning before starting next video
        tell application "SystemUIServer"
            activate
            repeat
                display alert "Clip Combining Script will begin running. Please do not type or click on anything until next 'OK' alert appears." buttons {"Delay 10 seconds", "OK"} default button 2 giving up after 10
                set x to button returned of result
                if x is "OK" then
                    exit repeat
                else if x is "Delay 10 seconds" then
                    delay 10
                else
                    exit repeat
                end if
            end repeat
        end tell

        tell application "Finder"
            --get current folder
            set currentFolder to item n of subfolderList

            --get name of folder as text
            set folderName to name of currentFolder
            set folderText to folderName as text

            --make list of videos in folder
            set currentVideos to every file of folder currentFolder

            --count number of videos
            set numFiles to count items of currentVideos

            --open folder
            open currentFolder
            activate
        end tell

        tell application "System Events"
            --highlight first video (down arrow)
            key code 125
        end tell

        tell application "QuickTime Player"
            open item 1 of currentVideos
            delay 3
            activate
        end tell

        tell application "System Events"
            --show clips (cmd E)
            key code 14 using {command down}
            delay 1
        end tell

        repeat (numFiles - 1) times

            tell application "Finder"
                activate
                delay 1
            end tell

            tell application "System Events"

                --go down one video (down arrow)
                key code 125
                delay 1

                --copy video (cmd C)
                key code 8 using {command down}
                delay 2

            end tell

            tell application "QuickTime Player"
                activate
            end tell

            tell application "System Events"

                --go to end of first video (option right arrow)
                key code 124 using {option down}

                --paste copied clip (cmd V)
                key code 9 using {command down}
                delay 2

            end tell

        end repeat

        tell application "System Events"
            --exit clip mode (enter)
            delay 6
            key code 76
        end tell

        tell application "System Events"
            --close window (cmd W)
            key code 13 using {command down}
            delay 2

            --name file same as folder name
            keystroke folderText

            --save (enter)
            key code 76
            delay 2
        end tell

        tell application "System Events"
            --minimize QuickTime (cmd M)
            key code 46 using {command down}
            delay 2
        end tell

        --close Finder window
        tell application "Finder"
            activate
        end tell
        tell application "System Events"
            --cmd W
            key code 13 using {command down}
        end tell

        --give ok alert
        tell application "SystemUIServer"
            activate
            display alert "OK" giving up after 10
        end tell

    end repeat

    return input

end run
    
posta nsea4 08.08.2018 - 20:01
fonte

0 risposte

Leggi altre domande sui tag