chromium/media/gpu/vaapi/vaapi_jpeg_decoder.h

// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef MEDIA_GPU_VAAPI_VAAPI_JPEG_DECODER_H_
#define MEDIA_GPU_VAAPI_VAAPI_JPEG_DECODER_H_

#include <stdint.h>

#include <memory>

#include "media/gpu/vaapi/vaapi_image_decoder.h"

namespace media {
namespace fuzzing {
class VaapiJpegDecoderWrapper;
}  // namespace fuzzing

struct JpegFrameHeader;
struct JpegParseResult;
class ScopedVAImage;

// Returns the internal format required for a JPEG image given its parsed
// |frame_header|. If the image's subsampling format is not one of 4:2:0, 4:2:2,
// or 4:4:4, returns kInvalidVaRtFormat.
unsigned int VaSurfaceFormatForJpeg(const JpegFrameHeader& frame_header);

class VaapiJpegDecoder : public VaapiImageDecoder {};

}  // namespace media

#endif  // MEDIA_GPU_VAAPI_VAAPI_JPEG_DECODER_H_