Bug 1237689 - Enable Oculus hardware latency tester r=daoshengmu
- Generate and pass sequential frame indexes into the ovr_GetTrackingState call and the corresponding call to ovr_SubmitFrame MozReview-Commit-ID: 5tJl5YJt7Eo
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include "nsDebug.h" // for printf_stderr, NS_ASSERTION
|
||||
#include "nsXULAppAPI.h" // for XRE_GetProcessType, etc
|
||||
#include "TextureClientSharedSurface.h"
|
||||
#include "VRManagerChild.h"
|
||||
|
||||
using namespace mozilla::gfx;
|
||||
using namespace mozilla::gl;
|
||||
@@ -125,6 +126,7 @@ CanvasClient2D::Update(gfx::IntSize aSize, ClientCanvasLayer* aLayer)
|
||||
t->mTextureClient = mBuffer;
|
||||
t->mPictureRect = nsIntRect(nsIntPoint(0, 0), mBuffer->GetSize());
|
||||
t->mFrameID = mFrameID;
|
||||
t->mInputFrameID = VRManagerChild::Get()->GetInputFrameID();
|
||||
GetForwarder()->UseTextures(this, textures);
|
||||
mBuffer->SyncWithObject(GetForwarder()->GetSyncObject());
|
||||
}
|
||||
@@ -481,6 +483,11 @@ CanvasClientSharedSurface::Updated()
|
||||
t->mTextureClient = mFront;
|
||||
t->mPictureRect = nsIntRect(nsIntPoint(0, 0), mFront->GetSize());
|
||||
t->mFrameID = mFrameID;
|
||||
// XXX TODO - This reference to VRManagerChild will be moved with the
|
||||
// implementation of the WebVR 1.0 API, which will enable
|
||||
// the inputFrameID to be passed through Javascript with
|
||||
// the new VRDisplay API.
|
||||
t->mInputFrameID = VRManagerChild::Get()->GetInputFrameID();
|
||||
forwarder->UseTextures(this, textures);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user