Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: media/gpu/mojo/jpeg_decoder.mojom

Issue 2905823002: Add Mojo interfaces for GpuJpegDecodeAccelerator and GpuJpegDecodeAcceleratorHost (Closed)
Patch Set: added //ui/gfx/geometry/mojo to deps Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « media/gpu/mojo/OWNERS ('k') | media/mojo/interfaces/media_types.mojom » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 module media.mojom;
6
7 import "media/mojo/interfaces/media_types.mojom";
8 import "ui/gfx/geometry/mojo/geometry.mojom";
9
10 enum Error {
11 NO_ERRORS,
12 INVALID_ARGUMENT,
13 UNREADABLE_INPUT,
14 PARSE_JPEG_FAILED,
15 UNSUPPORTED_JPEG,
16 PLATFORM_FAILURE,
17 };
18
19 struct JpegDecodeInfo {
20 BitstreamBuffer input_buffer;
21 gfx.mojom.Size coded_size;
22 handle<shared_buffer> output_handle;
23 uint32 output_buffer_size;
24 };
25
26 interface GpuJpegDecodeAcceleratorClient {
27 // Report decode status.
28 OnDecodeAck(int32 bitstream_buffer_id, Error error);
29 };
30
31 interface GpuJpegDecodeAccelerator {
32 // Create and initialize a hardware jpeg decoder.
33 // Created decoder should be freed with Uninitialize() when no longer needed.
34 Initialize(GpuJpegDecodeAcceleratorClient client) => (bool success);
chfremer 2017/05/30 18:07:24 nit: Comment is slightly confusing. If we say "Cre
Chandan 2017/05/31 13:19:58 Uninitialize() is most likely to be removed. Hence
35
36 // Decode one JPEG image from shared memory |input_buffer_handle| with size
37 // |input_buffer_size|. The input buffer is associated with |input_buffer_id|
38 // and the size of JPEG image is |coded_size|. Decoded I420 frame data will
39 // be put onto shared memory associated with |output_video_frame_handle|
40 // with size limit |output_buffer_size|.
41 Decode(JpegDecodeInfo info);
42
43 // TODO(c.padhi): This method might not be required, see
44 // http://crbug.com/699255.
45 // Destroy request to the decoder.
46 Uninitialize();
47 };
OLDNEW
« no previous file with comments | « media/gpu/mojo/OWNERS ('k') | media/mojo/interfaces/media_types.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698