예제 #1
0
    public void executeFuncinRenderThread()
    {
        if ((WaveVR_Overlay.instance.mtexture.textureId != (uint)0) && (WaveVR_Overlay.instance.getOverlayTextureId() != (uint)0))
        {
            Log.d(LOG_TAG, "executeFuncinRenderThread overlay texture ID: " + WaveVR_Overlay.instance.getOverlayTextureId() + ", image texture ID: " + WaveVR_Overlay.instance.mtexture.textureId);
            wvr_overlay.WVR_OverlayError _resultSetTextureId = Interop_overlay.WVR_SetOverlayTextureId(WaveVR_Overlay.instance.getOverlayTextureId(), ref WaveVR_Overlay.instance.mtexture);

            if (_resultSetTextureId == wvr_overlay.WVR_OverlayError.WVR_OverlayError_None)
            {
                wvr_overlay.WVR_OverlayError _resultShowOverlay = Interop_overlay.WVR_ShowOverlay(overlaytextureid);
                Log.d(LOG_TAG, "show OverlayError " + _resultShowOverlay.ToString());

                if (_resultShowOverlay == wvr_overlay.WVR_OverlayError.WVR_OverlayError_None)
                {
                    isShowOverlay = true;
                }
                else
                {
                    Log.e(LOG_TAG, "Update overlay texture fail: " + _resultShowOverlay.ToString());
                }
            }
            else
            {
                Log.d(LOG_TAG, "set WVR_SetOverlayTextureId OverlayError: " + _resultSetTextureId.ToString());
            }
        }
        else
        {
            Log.e(LOG_TAG, "Neither overlay texture ID or image texture ID is 0!");
        }
    }
예제 #2
0
 public void DelOverlay()
 {
     wvr_overlay.WVR_OverlayError _result = Interop_overlay.WVR_DelOverlay(overlaytextureid);
     if (_result != wvr_overlay.WVR_OverlayError.WVR_OverlayError_None)
     {
         Log.d(LOG_TAG, "Del OverlayError " + _result.ToString());
     }
 }
예제 #3
0
 private void setOverlayPosition()
 {
     position.x = 0.0f;
     position.y = 0.0f;
     position.z = -0.4f;
     wvr_overlay.WVR_OverlayError _resultposition = Interop_overlay.WVR_SetOverlayFixedPosition(overlaytextureid, ref position);
     if (_resultposition != wvr_overlay.WVR_OverlayError.WVR_OverlayError_None)
     {
         Log.e(LOG_TAG, "set OverlayPositionError: " + _resultposition.ToString());
     }
 }
예제 #4
0
 public void HideOverlay()
 {
     wvr_overlay.WVR_OverlayError _result = Interop_overlay.WVR_HideOverlay(overlaytextureid);
     if (_result == wvr_overlay.WVR_OverlayError.WVR_OverlayError_None)
     {
         isShowOverlay = false;
     }
     else
     {
         Log.e(LOG_TAG, "WVR_HideOverlay fail: " + _result.ToString() + ", Overlayid: " + overlaytextureid);
     }
 }
예제 #5
0
 private void GenOverlay()
 {
     wvr_overlay.WVR_OverlayError _result = Interop_overlay.WVR_GenOverlay(ref overlaytextureid);
     Log.d(LOG_TAG, "Gen OverlayError: " + _result.ToString() + ", overlaytextureid = " + overlaytextureid);
 }