gecko-dev/dom/canvas/PWebGL.ipdl

58 строки
2.0 KiB
Plaintext

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
* vim: sw=2 ts=8 et :
*/
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
include protocol PCompositorBridge;
include protocol PLayerTransaction;
using mozilla::layers::CompositableHandle from "mozilla/layers/LayersTypes.h";
using mozilla::webgl::ContextLossReason from "mozilla/dom/WebGLIpdl.h";
using std::string from "ipc/IPCMessageUtils.h";
using mozilla::webgl::InitContextDesc from "mozilla/dom/WebGLIpdl.h";
using mozilla::webgl::InitContextResult from "mozilla/dom/WebGLIpdl.h";
using mozilla::HostWebGLCommandSinkP from "mozilla/dom/WebGLCrossProcessCommandQueue.h";
using mozilla::HostWebGLCommandSinkI from "mozilla/dom/WebGLCrossProcessCommandQueue.h";
using mozilla::dom::IpdlQueueBuffer from "mozilla/dom/IpdlQueue.h";
using mozilla::dom::IpdlQueueBuffers from "mozilla/dom/IpdlQueue.h";
namespace mozilla {
namespace dom {
/**
* Represents the connection between a WebGLChild actor that issues WebGL
* command from the content process, and a WebGLParent in the compositor
* process that runs the commands.
*/
sync refcounted protocol PWebGL
{
manager PCompositorBridge;
parent:
sync Initialize(InitContextDesc desc, UniquePtr<HostWebGLCommandSinkP> sinkP,
UniquePtr<HostWebGLCommandSinkI> sinkI)
returns (InitContextResult res);
async __delete__();
// DLP: TODO: Does this need to be sync?
sync UpdateCompositableHandle(PLayerTransaction aLayerTrans,
CompositableHandle aHandle);
sync ExchangeIpdlQueueData(IpdlQueueBuffer aMsg) returns (IpdlQueueBuffers aResponse);
child:
async JsWarning(string text);
// Tell client that this queue needs to be shut down
async OnContextLoss(ContextLossReason aReason);
both:
async TransmitIpdlQueueData(IpdlQueueBuffer aData);
};
} // dom
} // mozilla