fmang / opustags

Ogg Opus tags editor
BSD 3-Clause "New" or "Revised" License
75 stars 10 forks source link

Add support for reading header packets spanning multiple pages #59

Closed halcyonseeker closed 1 year ago

halcyonseeker commented 1 year ago

Hi,

I'm trying to use opustags (built just now from the master branch) to embed lyrics in my music collection, but I keep running into this error message no matter which command-line options I pass:

error: Reading header packets spanning multiple pages are not yet supported. Please file an issue to make your wish known.

The file that's causing this issue was downloaded from YouTube with:

yt-dlp --extract-audio --audio-format opus --audio-quality 0 --embed-metadata --embed-thumbnail --sponsorblock-mark all --output '%(artist)s - %(track)s.%(ext)s' 'https://youtube.com/watch?v=xgIU9e1W0uU'
zvezdochiot commented 1 year ago

Hi @halcyonseeker .

youtube-dl --extract-audio --audio-format opus --audio-quality 0 --add-metadata --embed-thumbnail --output '%(artist)s - %(track)s.%(ext)s' 'https://youtube.com/watch?v=xgIU9e1W0uU'

opuscomment:

opuscomment SKÁLD\ -\ Gleipnir.opus 
language=und
handler_name=ISO Media file produced by Google Inc.
encoder=Lavc58.91.100 libopus
major_brand=isom
minor_version=512
compatible_brands=isomiso2mp41
title=Gleipnir
date=20180712
DESCRIPTION=Provided to YouTube by Universal Music Group

        Gleipnir · SKÁLD

        SKÁLD

        ℗ 2018 Decca Records France

        Released on: 2018-07-20

        Producer, Studio  Personnel, Recording  Engineer, Associated  Performer, Percussion, Interprète  Instrumental, Keyboards, Programming: Christophe Voisin-Boisvinet
        Producer, Executive  Producer: Edouard Brane
        Studio  Personnel, Recording  Engineer, Mixer: Adrien Thore
        Studio  Personnel, Mastering  Engineer: Alexis Bardinet
        Associated  Performer, Vocals, Interprète  Instrumental: Pierrick Valence
        Associated  Performer, Vocals: Xavier Bertrand
        Associated  Performer, Vocals: Mathieu Haussy
        Associated  Performer, Vocals: Justine Galmiche
        Associated  Performer, Percussion: Nicolas Montazaud
        Associated  Performer, Interprète  Instrumental: Jaufré Darroux
        Associated  Performer, Flute: Maxence des Oiseaux
        Author: Traditionnel
        Composer: Christophe Voisin-Boisvinet

        Auto-generated by YouTube.
purl=https://www.youtube.com/watch?v=xgIU9e1W0uU
artist=SKÁLD
album=SKÁLD

libopustags:

LD_LIBRARY_PATH=. ./opustags SKÁLD\ -\ Gleipnir.opus 
language=und
handler_name=ISO Media file produced by Google Inc.
encoder=Lavc58.91.100 libopus
major_brand=isom
minor_version=512
compatible_brands=isomiso2mp41
title=Gleipnir
date=20180712
DESCRIPTION=Provided to YouTube by Universal Music Group

Gleipnir · SKÁLD

SKÁLD

℗ 2018 Decca Records France

Released on: 2018-07-20

Producer, Studio  Personnel, Recording  Engineer, Associated  Performer, Percussion, Interprète  Instrumental, Keyboards, Programming: Christophe Voisin-Boisvinet
Producer, Executive  Producer: Edouard Brane
Studio  Personnel, Recording  Engineer, Mixer: Adrien Thore
Studio  Personnel, Mastering  Engineer: Alexis Bardinet
Associated  Performer, Vocals, Interprète  Instrumental: Pierrick Valence
Associated  Performer, Vocals: Xavier Bertrand
Associated  Performer, Vocals: Mathieu Haussy
Associated  Performer, Vocals: Justine Galmiche
Associated  Performer, Percussion: Nicolas Montazaud
Associated  Performer, Interprète  Instrumental: Jaufré Darroux
Associated  Performer, Flute: Maxence des Oiseaux
Author: Traditionnel
Composer: Christophe Voisin-Boisvinet

Auto-generated by YouTube.
purl=https://www.youtube.com/watch?v=xgIU9e1W0uU
artist=SKÁLD
album=SKÁLD

Good luck.

halcyonseeker commented 1 year ago

Thank you, I was able to get it to work with opuscomment. Further investigation revealed that opustags only yielded that error when the file had embedded cover art.

zvezdochiot commented 1 year ago

@halcyonseeker say:

Further investigation revealed that opustags only yielded that error when the file had embedded cover art.

This only applies to opustags (this), not libopustags.

Good luck.

fmang commented 1 year ago

Duplicate of #49.

A cover art included in the comments can indeed easily cause a multi-page OpusTags header.