#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "media/renderers/video_frame_yuv_mailboxes_holder.h"
#include <GLES3/gl3.h>
#include "base/logging.h"
#include "components/viz/common/gpu/raster_context_provider.h"
#include "components/viz/common/resources/shared_image_format.h"
#include "components/viz/common/resources/shared_image_format_utils.h"
#include "gpu/GLES2/gl2extchromium.h"
#include "gpu/command_buffer/client/client_shared_image.h"
#include "gpu/command_buffer/client/raster_interface.h"
#include "gpu/command_buffer/client/shared_image_interface.h"
#include "gpu/command_buffer/common/shared_image_usage.h"
#include "media/base/media_switches.h"
#include "media/base/video_util.h"
#include "third_party/skia/include/core/SkImageInfo.h"
#include "third_party/skia/include/core/SkYUVAPixmaps.h"
namespace media {
namespace {
viz::SharedImageFormat VideoPixelFormatToSharedImageFormat(
VideoPixelFormat video_format) { … }
}
VideoFrameYUVMailboxesHolder::VideoFrameYUVMailboxesHolder() = default;
VideoFrameYUVMailboxesHolder::~VideoFrameYUVMailboxesHolder() { … }
void VideoFrameYUVMailboxesHolder::ReleaseCachedData() { … }
const gpu::Mailbox& VideoFrameYUVMailboxesHolder::VideoFrameToMailbox(
const VideoFrame* video_frame,
viz::RasterContextProvider* raster_context_provider) { … }
SkYUVAInfo VideoFrameYUVMailboxesHolder::VideoFrameGetSkYUVAInfo(
const VideoFrame* video_frame) { … }
}