Ticket #5324: openglvid_1.diff

File openglvid_1.diff, 3.9 KB (added by anonymous, 4 years ago)
  • libs/libmythtv/openglvideo.cpp

    diff -ur -X excl mythtvopengl/libs/libmythtv/openglvideo.cpp mythtvopengl1/libs/libmythtv/openglvideo.cpp
    old new  
    352352} 
    353353 
    354354// locking ok 
    355 bool OpenGLVideo::ReInit(OpenGLContext *glcontext, bool colour_control, 
    356                          bool onscreen, QSize video_size, QRect visible_rect, 
    357                          QRect video_rect, QRect frame_rect, 
    358                          bool viewport_control, bool osd) 
    359 { 
    360     VERBOSE(VB_PLAYBACK, LOC + "Reinit"); 
    361  
    362     gl_context->MakeCurrent(true); 
    363  
    364     QString harddeint   = GetDeinterlacer(); // only adds back deinterlacer 
    365     QString softdeint   = softwareDeinterlacer; 
    366     bool    interlacing = hardwareDeinterlacing; 
    367     bool    resize      = videoResize; 
    368     QRect   resize_rect = videoResizeRect; 
    369  
    370     Teardown(); 
    371  
    372     bool success = Init(glcontext, colour_control, onscreen, video_size, 
    373                         visible_rect, video_rect, frame_rect, 
    374                         viewport_control, osd); 
    375  
    376     if (harddeint != "") 
    377         success &= AddDeinterlacer(harddeint); 
    378  
    379     softwareDeinterlacer = softdeint; 
    380     SetDeinterlacing(interlacing); 
    381  
    382     if (resize) 
    383         SetVideoResize(resize_rect); 
    384  
    385     return success; 
    386 } 
    387  
    388 // locking ok 
    389355bool OpenGLVideo::AddFilter(OpenGLFilterType filter) 
    390356{ 
    391357    if (filters.count(filter)) 
  • libs/libmythtv/openglvideo.h

    diff -ur -X excl mythtvopengl/libs/libmythtv/openglvideo.h mythtvopengl1/libs/libmythtv/openglvideo.h
    old new  
    5858              QSize video_size, QRect visible_rect, 
    5959              QRect video_rect, QRect frame_rect, 
    6060              bool viewport_control, bool osd = FALSE); 
    61     bool ReInit(OpenGLContext *gl, bool colour_control, bool onscreen, 
    62               QSize video_size, QRect visible_rect, 
    63               QRect video_rect, QRect frame_rect, 
    64               bool viewport_control, bool osd = FALSE); 
    6561 
    6662    void UpdateInputFrame(const VideoFrame *frame); 
    6763    void UpdateInput(const unsigned char *buf, const int *offsets, 
     
    159155              QRect, QRect, bool, bool osd = false) 
    160156        { (void) osd; return false; } 
    161157 
    162     bool ReInit(OpenGLContext*, bool, bool, QSize, QRect, 
    163                 QRect, QRect, bool, bool osd = false) 
    164         { (void) osd; return false; } 
    165  
    166158    void UpdateInputFrame(const VideoFrame*) { } 
    167159    void UpdateInput(const unsigned char*, const int*, uint, int, QSize) { } 
    168160 
  • libs/libmythtv/videoout_xv.cpp

    diff -ur -X excl mythtvopengl/libs/libmythtv/videoout_xv.cpp mythtvopengl1/libs/libmythtv/videoout_xv.cpp
    old new  
    31703170    { 
    31713171        VERBOSE(VB_PLAYBACK, LOC + "Re-initialise PiP."); 
    31723172 
    3173         bool success = gl_pipchain->ReInit( 
    3174             gl_context, db_use_picture_controls, 
    3175             true, QSize(pipVideoWidth, pipVideoHeight), 
    3176             position, position, 
    3177             QRect(0, 0, pipVideoWidth, pipVideoHeight), false); 
     3173        delete gl_pipchain; 
     3174        gl_pipchain = new OpenGLVideo(); 
     3175        bool success = gl_pipchain->Init( 
     3176             gl_context, db_use_picture_controls, 
     3177             true, QSize(pipVideoWidth, pipVideoHeight), 
     3178             position, position, 
     3179             QRect(0, 0, pipVideoWidth, pipVideoHeight), false); 
    31783180 
    31793181        gl_pipchain->SetMasterViewport(gl_videochain->GetViewPort()); 
    31803182        if (!success)