#66 Escaping double-quotes in chapter names when converting to xml chapter format for mp4

None
closed
nobody
5
2013-02-20
2013-02-12
Eli Bildirici
No

When using the MP4 muxer with an iDevice target, OGG-format chapter files are converted to the xml chapters that iDevices support by a simple method in FileUtil.cs. As written, however, it does not escape double-quotes in chapter names. This is a problem because in the xml format, chapter names are bookended by quotes, so if there is a quote mark in the chapter title, the chapter name is truncated, and the structure of the entire xml file is broken. When this happens, the mp4 file fails to mux. This simple patch replaces all " with ". It has been tested as effective in mpc-hc x64, xbmc frodo for rpi, and the iOS 6 video player.

Also in this patch is a removal of a switch that prevents chapters from being added the 'Nero Digital' way if the target is specified as an iDevice. In other words, both ogg format and xml format chapters are muxed into the MP4 file. This means that software and devices that don't understand xml chapters - for example, mpc-hc cannot read them without special filters like lav - have something to fall back on. Adding the ogg chapters and xml chapters does NOT break compatibility with software that can read both (mpc-hc with filters), or with iDevices (which only recognize xml chapters).

1 Attachments

Discussion

  • Eli Bildirici
    Eli Bildirici
    2013-02-12

    This simple patch replaces all " with ".'
    I mean, ampersand-quot;

     
  • Kurtnoise
    Kurtnoise
    2013-02-20

    Applied in rev 2298 & 2299. Thanks...

     
  • Kurtnoise
    Kurtnoise
    2013-02-20

    • status: open --> closed
    • milestone: -->