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

Unified Diff: components/mus/public/interfaces/command_buffer.mojom

Issue 1686543004: mus: Modify mojo command buffer to match current chrome gpu ipc. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address review issues Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/mus/gles2/command_buffer_impl_observer.h ('k') | mojo/gles2/command_buffer_client_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/public/interfaces/command_buffer.mojom
diff --git a/components/mus/public/interfaces/command_buffer.mojom b/components/mus/public/interfaces/command_buffer.mojom
index d48f9873c1273ac9ce626da6f588b1acd6da013d..8b082569335e95edd64f42a5a08e66728c597158 100644
--- a/components/mus/public/interfaces/command_buffer.mojom
+++ b/components/mus/public/interfaces/command_buffer.mojom
@@ -6,6 +6,8 @@ module mus.mojom;
import "gpu/command_buffer/common/capabilities.mojom";
import "gpu/command_buffer/common/command_buffer.mojom";
+import "gpu/command_buffer/common/mailbox.mojom";
+import "gpu/command_buffer/common/sync_token.mojom";
import "ui/mojo/geometry/geometry.mojom";
struct CommandBufferInitializeResult {
@@ -14,16 +16,24 @@ struct CommandBufferInitializeResult {
gpu.mojom.Capabilities capabilities;
};
-interface CommandBufferLostContextObserver {
- DidLoseContext(int32 context_lost_reason);
+interface CommandBufferClient {
+ Destroyed(int32 context_lost_reason,
+ int32 error);
+ SignalAck(uint32 id);
+ // TODO(penghuang): support latency_info and use gfx::SwapResult for result.
+ SwapBuffersCompleted(/* array<ui.mojom.LatencyInfo> latency_info, */
+ int32 result);
+ UpdateState(gpu.mojom.CommandBufferState state);
+ // TODO(penghuang): use base::TimeTicks & base::TimeDelta.
+ UpdateVSyncParameters(int64 timebase, int64 interval);
};
interface CommandBuffer {
// Initialize attempts to initialize the command buffer.
// If the context is lost after creation the LostContext method on the
- // CommandBufferLostContextObserver's will be called then this pipe will be
+ // CommandBufferClient's will be called then this pipe will be
// closed.
- Initialize(CommandBufferLostContextObserver lost_observer,
+ Initialize(CommandBufferClient client,
handle<shared_buffer> shared_state,
array<int32> attribs) => (CommandBufferInitializeResult? result);
SetGetBuffer(int32 buffer);
@@ -32,7 +42,6 @@ interface CommandBuffer {
RegisterTransferBuffer(
int32 id, handle<shared_buffer> transfer_buffer, uint32 size);
DestroyTransferBuffer(int32 id);
-
CreateImage(int32 id,
handle memory_handle,
int32 type,
@@ -40,4 +49,13 @@ interface CommandBuffer {
int32 format,
int32 internal_format);
DestroyImage(int32 id);
+ CreateStreamTexture(uint32 client_texture_id)
+ => (int32 stream_id, bool succeeded);
+ ProduceFrontBuffer(gpu.mojom.Mailbox mailbox);
+ SignalQuery(uint32 query, uint32 signal_id);
+ SignalSyncToken(gpu.mojom.SyncToken sync_token, uint32 signal_id);
+ WaitForGetOffsetInRange(int32 start, int32 end)
+ => (gpu.mojom.CommandBufferState state);
+ WaitForTokenInRange(int32 start, int32 end)
+ => (gpu.mojom.CommandBufferState state);
};
« no previous file with comments | « components/mus/gles2/command_buffer_impl_observer.h ('k') | mojo/gles2/command_buffer_client_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698