Ticket #2283: 2283.patch

File 2283.patch, 1.3 KB (added by danielk, 18 years ago)

Fix. Note, I do not have a Mac to test on so this is uncompiled & untested (but should work)

  • libs/libmythtv/videoout_quartz.cpp

     
    11711171{
    11721172    Started = 0;
    11731173
    1174     pauseFrame.buf = NULL;
     1174    init(&pauseFrame, FMT_YV12, NULL, 0, 0, 0, 0);
    11751175
    11761176    data = new QuartzData();
    11771177    data->views.setAutoDelete(true);
     
    14261426
    14271427    // Set up pause and scratch frames
    14281428    if (pauseFrame.buf)
     1429    {
    14291430        delete [] pauseFrame.buf;
     1431        init(&pauseFrame, FMT_YV12, NULL, 0, 0, 0, 0);
     1432    }
    14301433
    14311434    VideoFrame *scratch = vbuffers.GetScratchFrame();
    14321435
    1433     pauseFrame.height = scratch->height;
    1434     pauseFrame.width  = scratch->width;
    1435     pauseFrame.bpp    = scratch->bpp;
    1436     pauseFrame.size   = scratch->size;
    1437     pauseFrame.buf    = new unsigned char[pauseFrame.size];
     1436    init(&pauseFrame, FMT_YV12, new unsigned char[scratch->size],
     1437         scratch->width, scratch->height, scratch->bpp, scratch->size);
     1438
    14381439    pauseFrame.frameNumber = scratch->frameNumber;
    14391440
    14401441    // Set up pixel storage and image description for source
     
    15511552    data->pixelLock.unlock();
    15521553
    15531554    if (pauseFrame.buf)
     1555    {
    15541556        delete [] pauseFrame.buf;
     1557        init(&pauseFrame, FMT_YV12, NULL, 0, 0, 0, 0);
     1558    }
    15551559
    15561560    vbuffers.DeleteBuffers();
    15571561}