예제 #1
0
 static extern private int ohmd_device_geti(IntPtr device, ohmd_int_value val, out int out_value);
예제 #2
0
파일: OpenHMD.cs 프로젝트: sjb8100/C3DE
 public static extern int ohmd_device_geti(IntPtr device, ohmd_int_value val, out int out_value);
예제 #3
0
        /// <summary>
        /// Gets integer information from the device.
        /// </summary>
        /// <param name="device">The opened device you want information from.</param>
        /// <param name="informationType">Enum value for what kind of information is needed.</param>
        /// <returns>Returns an integer corresponding to the informationType which is requested.</returns>
        public int getIntInformation(Device device, ohmd_int_value informationType)
        {
            if(!openedDevices.ContainsKey(device.Index))
            {
                throw new DeviceNotOpenedException(String.Format("Device with index {0} and name {1} is not yet openend. Please open first.", device.Index, device.Product));
            }
            IntPtr hmd = openedDevices[device.Index];
            int output = 0;
            ohmd_device_geti(hmd, informationType, out output);

            return output;
        }