1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef GFX_VR_GPU_PARENT_H
8 #define GFX_VR_GPU_PARENT_H
10 #include "mozilla/gfx/PVRGPUParent.h"
11 #include "VRService.h"
16 class VRGPUParent final
: public PVRGPUParent
{
17 NS_INLINE_DECL_THREADSAFE_REFCOUNTING(VRGPUParent
, final
)
19 friend class PVRGPUParent
;
22 static RefPtr
<VRGPUParent
> CreateForGPU(Endpoint
<PVRGPUParent
>&& aEndpoint
);
23 virtual void ActorDestroy(ActorDestroyReason aWhy
) override
;
27 void Bind(Endpoint
<PVRGPUParent
>&& aEndpoint
);
28 mozilla::ipc::IPCResult
RecvStartVRService();
29 mozilla::ipc::IPCResult
RecvStopVRService();
30 mozilla::ipc::IPCResult
RecvPuppetReset();
31 mozilla::ipc::IPCResult
RecvPuppetSubmit(const nsTArray
<uint64_t>& aBuffer
);
32 mozilla::ipc::IPCResult
RecvPuppetCheckForCompletion();
35 explicit VRGPUParent(ipc::EndpointProcInfo aChildProcess
);
38 void DeferredDestroy();
40 #if !defined(MOZ_WIDGET_ANDROID)
41 RefPtr
<VRService
> mVRService
;
45 DISALLOW_COPY_AND_ASSIGN(VRGPUParent
);
49 } // namespace mozilla
51 #endif // GFX_VR_CONTENT_PARENT_H