Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit edc42f0c authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "C2SoftVpxEnc: Add support for encoding from a larger graphic block"

parents 84b71232 fdd58cb1
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -455,8 +455,8 @@ void C2SoftVpxEnc::process(

    const C2ConstGraphicBlock inBuffer =
        inputBuffer->data().graphicBlocks().front();
    if (inBuffer.width() != mSize->width ||
        inBuffer.height() != mSize->height) {
    if (inBuffer.width() < mSize->width ||
        inBuffer.height() < mSize->height) {
        ALOGE("unexpected Input buffer attributes %d(%d) x %d(%d)",
              inBuffer.width(), mSize->width, inBuffer.height(),
              mSize->height);
@@ -467,8 +467,8 @@ void C2SoftVpxEnc::process(
    bool eos = ((work->input.flags & C2FrameData::FLAG_END_OF_STREAM) != 0);
    vpx_image_t raw_frame;
    const C2PlanarLayout &layout = rView->layout();
    uint32_t width = rView->width();
    uint32_t height = rView->height();
    uint32_t width = mSize->width;
    uint32_t height = mSize->height;
    if (width > 0x8000 || height > 0x8000) {
        ALOGE("Image too big: %u x %u", width, height);
        work->result = C2_BAD_VALUE;