• Sunny Sachanandani's avatar
    Reland "Fix video quad rect and surface output rect" · 56f3274d
    Sunny Sachanandani authored
    This is a reland of 1dfd4418
    
    Original change's description:
    > Fix video quad rect and surface output rect
    >
    > Video surface output rect didn't take rotation into account so when
    > SurfaceAggregator would stretch content to fill bounds, it would end up
    > with the wrong scaling factors (squash in one dimension and expand in
    > another) since the surface quad's bounds (in the embedder) were rotated.
    >
    > To work around this (or by accident), VideoFrameResourceProvider was
    > passing the rotated size as the quad's rect which doesn't make sense
    > intuitively.  This also worked by accident with DirectComposition
    > overlays because of applying another scaling which would fix the aspect
    > ratio again.
    >
    > This change makes it possible to use the |quad_to_target_transform| as
    > is, without having to apply an aspect ratio correcting scaling, and to
    > assume that the quad's rect is in the pre-transform space.
    >
    > Bug: 904035
    > Change-Id: Ia55e44f1f2b49b8d368a97af54f3ce9d90a81234
    > Reviewed-on: https://chromium-review.googlesource.com/c/1334971
    > Reviewed-by: enne <enne@chromium.org>
    > Reviewed-by: Kenneth Russell <kbr@chromium.org>
    > Reviewed-by: Frank Liberato <liberato@chromium.org>
    > Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#608495}
    
    TBR=enne@chromium.org,kbr@chromium.org,liberato@chromium.org
    
    Bug: 904035
    Change-Id: I278a0ea2c5507f01ea13b31d2090b5f99537c7c3
    Reviewed-on: https://chromium-review.googlesource.com/c/1338418Reviewed-by: default avatarSunny Sachanandani <sunnyps@chromium.org>
    Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#608596}
    56f3274d
video_resource_updater.cc 47.1 KB