Ticket #3797: pillarbars.2.diff

File pillarbars.2.diff, 2.5 KB (added by Juppers, 13 years ago)
  • libs/libmythtv/videoout_xv.h

     
    186186    int                  XJ_screenwidth;
    187187    int                  XJ_screenheight;
    188188    bool                 XJ_started;
     189    Colormap             cmap;
     190    XColor               color, colorrgb;
    189191
    190192    // Used for all non-XvMC drawing
    191193    VideoFrame           av_pause_frame;
  • libs/libmythtv/videoout_xv.cpp

     
    25592559    needrepaint = false;
    25602560    xv_need_bobdeint_repaint = false;
    25612561
    2562     // Draw black in masked areas
    2563     XSetForeground(XJ_disp, XJ_gc, XJ_black);
     2562    // Set the masked area to black unless Gray Pillarbars was selected
     2563    cmap = DefaultColormap (XJ_disp, XJ_screen_num);
     2564    int db_graypillars       = gContext->GetNumSetting("GrayPillars",     0);
     2565    if (db_graypillars == 1)
     2566    {
     2567        XAllocNamedColor (XJ_disp, cmap, "gray25", &color, &colorrgb);
     2568    }
     2569    else
     2570    {
     2571        XAllocNamedColor (XJ_disp, cmap, "gray0", &color, &colorrgb);
     2572    }
    25642573
     2574    // Draw black or gray in masked areas
     2575    XSetForeground(XJ_disp, XJ_gc, color.pixel);
     2576
    25652577    if (display_video_rect.left() > display_visible_rect.left())
    25662578    { // left
    25672579        XFillRectangle(XJ_disp, XJ_curwin, XJ_gc,
  • programs/mythfrontend/globalsettings.cpp

     
    15391539    return gc;
    15401540}
    15411541
     1542static HostCheckBox *GrayPillars()
     1543{
     1544    HostCheckBox *gc = new HostCheckBox("GrayPillars");
     1545    gc->setLabel(QObject::tr("Make pillarboxes gray"));
     1546    gc->setValue(true);
     1547    gc->setHelpText(QObject::tr("If enabled, Pillarboxes will be gray instead of black. "
     1548                    "Useful for people with screens subject to burn-in."));
     1549    return gc;
     1550}
     1551
    15421552static HostComboBox *AspectOverride()
    15431553{
    15441554    HostComboBox *gc = new HostComboBox("AspectOverride");
     
    36173627    general->addChild(RealtimePriority());
    36183628    general->addChild(UseVideoTimebase());
    36193629    general->addChild(DecodeExtraAudio());
     3630    general->addChild(GrayPillars());
    36203631    general->addChild(AspectOverride());
    36213632    general->addChild(PIPLocation());
    36223633    addChild(general);