示例#1
0
        public HmdMatrix44 GetEyeMatrix(HmdEye Eye)
        {
            CheckIfUsable();

            return(NativeHelpers.ConvertStruct <HmdMatrix44>(NativeMethods.VR_Hmd_GetEyeMatrix((int)Eye), Marshal.SizeOf(typeof(HmdMatrix44))));
            //return NativeHelpers.ConvertStructToClass<HmdMatrix44>(NativeMethods.VR_Hmd_GetEyeMatrix((int)Eye), Marshal.SizeOf(typeof(HmdMatrix44)));
        }
        public HmdMatrix44 GetProjectionMatrix(HmdEye Eye, float NearZ, float FarZ, GraphicsAPIConvention ProjType)
        {
            CheckIfUsable();


            return NativeHelpers.ConvertStruct<HmdMatrix44>(NativeMethods.VR_Hmd_GetProjectionMatrix((int)Eye, NearZ, FarZ, (int)ProjType), Marshal.SizeOf(typeof(HmdMatrix44)));
        }
示例#3
0
        public HmdMatrix44 GetProjectionMatrix(HmdEye Eye, float NearZ, float FarZ, GraphicsAPIConvention ProjType)
        {
            CheckIfUsable();


            return(NativeHelpers.ConvertStruct <HmdMatrix44>(NativeMethods.VR_Hmd_GetProjectionMatrix((int)Eye, NearZ, FarZ, (int)ProjType), Marshal.SizeOf(typeof(HmdMatrix44))));
        }
        public void GetProjectionRaw(HmdEye Eye, out float Left, out float Right, out float Top, out float Bottom)
        {
            CheckIfUsable();

            Left = 0;
            Right = 0;
            Top = 0;
            Bottom = 0;

            NativeMethods.VR_Hmd_GetProjectionRaw((int)Eye, ref Left, ref Right, ref Top, ref Bottom);
        }
        public void GetEyeOutputViewport(HmdEye Eye, GraphicsAPIConvention APIType, out uint X, out uint Y, out uint Width, out uint Height)
        {
            CheckIfUsable();

            X = 0;
            Y = 0;
            Width = 0;
            Height = 0;

            NativeMethods.VR_Hmd_GetEyeOutputViewport((int)Eye, (int)APIType, ref X, ref Y, ref Width, ref Height);
        }
示例#6
0
        public void GetProjectionRaw(HmdEye Eye, out float Left, out float Right, out float Top, out float Bottom)
        {
            CheckIfUsable();

            Left   = 0;
            Right  = 0;
            Top    = 0;
            Bottom = 0;

            NativeMethods.VR_Hmd_GetProjectionRaw((int)Eye, ref Left, ref Right, ref Top, ref Bottom);
        }
示例#7
0
        public void GetEyeOutputViewport(HmdEye Eye, GraphicsAPIConvention APIType, out uint X, out uint Y, out uint Width, out uint Height)
        {
            CheckIfUsable();

            X      = 0;
            Y      = 0;
            Width  = 0;
            Height = 0;

            NativeMethods.VR_Hmd_GetEyeOutputViewport((int)Eye, (int)APIType, ref X, ref Y, ref Width, ref Height);
        }
        public HmdMatrix44 GetEyeMatrix(HmdEye Eye)
        {
            CheckIfUsable();

            return NativeHelpers.ConvertStruct<HmdMatrix44>(NativeMethods.VR_Hmd_GetEyeMatrix((int)Eye), Marshal.SizeOf(typeof(HmdMatrix44)));
            //return NativeHelpers.ConvertStructToClass<HmdMatrix44>(NativeMethods.VR_Hmd_GetEyeMatrix((int)Eye), Marshal.SizeOf(typeof(HmdMatrix44)));
        }
        public DistortionCoordinates ComputeDistortion(HmdEye Eye, float U, float V)
        {
            CheckIfUsable();

            return NativeHelpers.ConvertStruct<DistortionCoordinates>(NativeMethods.VR_Hmd_ComputeDistortion((int)Eye, U, V), Marshal.SizeOf(typeof(DistortionCoordinates)));
        }
示例#10
0
        public DistortionCoordinates ComputeDistortion(HmdEye Eye, float U, float V)
        {
            CheckIfUsable();

            return(NativeHelpers.ConvertStruct <DistortionCoordinates>(NativeMethods.VR_Hmd_ComputeDistortion((int)Eye, U, V), Marshal.SizeOf(typeof(DistortionCoordinates))));
        }