| // camera/mojo/gpu/jpeg_accelerator.mojom-params-data.h is auto generated by mojom_bindings_generator.py, do not edit |
| |
| // 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 CAMERA_MOJO_GPU_JPEG_ACCELERATOR_MOJOM_PARAMS_DATA_H_ |
| #define CAMERA_MOJO_GPU_JPEG_ACCELERATOR_MOJOM_PARAMS_DATA_H_ |
| |
| #include "mojo/public/cpp/bindings/lib/bindings_internal.h" |
| #include "mojo/public/cpp/bindings/lib/buffer.h" |
| |
| #if defined(__clang__) |
| #pragma clang diagnostic push |
| #pragma clang diagnostic ignored "-Wunused-private-field" |
| #endif |
| |
| namespace mojo::internal { |
| class ValidationContext; |
| } |
| |
| |
| namespace cros::mojom { |
| namespace internal { |
| class JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data { |
| public: |
| static bool Validate(const void* data, |
| mojo::internal::ValidationContext* validation_context); |
| |
| mojo::internal::StructHeader header_; |
| mojo::internal::Handle_Data jea; |
| uint8_t padfinal_[4]; |
| |
| private: |
| friend class mojo::internal::MessageFragment<JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data>; |
| |
| JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data(); |
| ~JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data() = delete; |
| }; |
| static_assert(sizeof(JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data) == 16, |
| "Bad sizeof(JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data)"); |
| class JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data { |
| public: |
| static bool Validate(const void* data, |
| mojo::internal::ValidationContext* validation_context); |
| |
| mojo::internal::StructHeader header_; |
| mojo::internal::Handle_Data jda; |
| uint8_t padfinal_[4]; |
| |
| private: |
| friend class mojo::internal::MessageFragment<JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data>; |
| |
| JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data(); |
| ~JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data() = delete; |
| }; |
| static_assert(sizeof(JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data) == 16, |
| "Bad sizeof(JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data)"); |
| |
| } // namespace internal |
| |
| |
| class JpegAcceleratorProvider_GetJpegEncodeAccelerator_ParamsDataView { |
| public: |
| JpegAcceleratorProvider_GetJpegEncodeAccelerator_ParamsDataView() = default; |
| |
| JpegAcceleratorProvider_GetJpegEncodeAccelerator_ParamsDataView( |
| internal::JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data* data, |
| mojo::Message* message) |
| : data_(data), message_(message) {} |
| |
| bool is_null() const { return !data_; } |
| template <typename UserType> |
| UserType TakeJea() { |
| UserType result; |
| bool ret = |
| mojo::internal::Deserialize<mojo::InterfaceRequestDataView<::cros::mojom::JpegEncodeAcceleratorInterfaceBase>>( |
| &data_->jea, &result, message_); |
| DCHECK(ret); |
| return result; |
| } |
| private: |
| internal::JpegAcceleratorProvider_GetJpegEncodeAccelerator_Params_Data* data_ = nullptr; |
| mojo::Message* message_ = nullptr; |
| }; |
| |
| |
| class JpegAcceleratorProvider_GetMjpegDecodeAccelerator_ParamsDataView { |
| public: |
| JpegAcceleratorProvider_GetMjpegDecodeAccelerator_ParamsDataView() = default; |
| |
| JpegAcceleratorProvider_GetMjpegDecodeAccelerator_ParamsDataView( |
| internal::JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data* data, |
| mojo::Message* message) |
| : data_(data), message_(message) {} |
| |
| bool is_null() const { return !data_; } |
| template <typename UserType> |
| UserType TakeJda() { |
| UserType result; |
| bool ret = |
| mojo::internal::Deserialize<mojo::InterfaceRequestDataView<::cros::mojom::MjpegDecodeAcceleratorInterfaceBase>>( |
| &data_->jda, &result, message_); |
| DCHECK(ret); |
| return result; |
| } |
| private: |
| internal::JpegAcceleratorProvider_GetMjpegDecodeAccelerator_Params_Data* data_ = nullptr; |
| mojo::Message* message_ = nullptr; |
| }; |
| |
| |
| |
| |
| |
| |
| } // cros::mojom |
| |
| #if defined(__clang__) |
| #pragma clang diagnostic pop |
| #endif |
| |
| #endif // CAMERA_MOJO_GPU_JPEG_ACCELERATOR_MOJOM_PARAMS_DATA_H_ |