[mythtv-users] non-printable character in CC track from Handbrake

Joey Morris rjmorris.list at zoho.com
Sat Sep 14 14:22:24 UTC 2013


Jim Stichnoth <stichnot at gmail.com> wrote on Sat, Sep 14, 2013 at 06:08:48AM -0700:
> On Fri, Sep 13, 2013 at 6:40 PM, Joey Morris <rjmorris.list at zoho.com> wrote:
> 
> > Thanks Jim. What did you use to see the rectangle outline with a
> > question mark in it? MythTV is the only place I've seen my rectangle.
> > I've looked at the log file in emacs, vi, and in the console, but each
> > of those seem to have performed the backspace operation instead of
> > displaying a symbol representing the backspace. I also tried creating
> > a hex dump using xxd, but that doesn't show the backspace either.
> >
> 
> This rectangle/question character was seen only in the mythfrontend OSD
> captions.  To experiment, I took an existing recording/video with a .srt
> file (in my case, an HD-PVR recording with a .srt file created using
> http://www.mythtv.org/wiki/Captions_with_HD-PVR), edited the .srt file in
> emacs, and manually added weird characters like \r, ^H, ^?, etc. to the
> ends of lines.  Whitespace characters like \r were stripped as expected,
> but other special characters became the question-mark-inside-rectangle
> symbol.  This is with the FreeMono font.  Notably, the ^H backspace
> character did seem to erase characters in the log output.

After a little experimentation in FormattedTextChunk::ToLogString in
subtitlescreen.cpp, I believe the weird character in my case is a null
character, not backspace. I added this to the log string:

    str += QString("last=%1 ").arg(text[text.length()-1].unicode());

and it displayed "last=0" in the log. Then I did this to the log
string:

    QString tmp = text;
    tmp.remove(QChar(0));
    str += QString(" text='%1'").arg(tmp);

and the log displayed the string as one would expect, that is, the
closing single quote was present.

Before I approach the Handbrake devs with this, can you think of any
reason MythTV would be introducing a null character? Or how I can
inspect the video file to find out if the nulls are in there?



More information about the mythtv-users mailing list