private void LogError(NdkCameraMetadataType requestedType) { ARDebug.LogErrorFormat( "Error getting value from CameraMetadataType due to type mismatch. " + "requested type = {0}, internal type = {1}\n" + "Are you sure you are querying the correct type?", requestedType, _type); }
/// <summary> /// Constructs CameraMetadataValue using long. This constructor only sets the long field /// in the struct, leaving the rest of the data to default value. /// </summary> /// <param name="longValue">The long value set to the struct.</param> public CameraMetadataValue(long longValue) { m_ByteValue = 0; m_IntValue = 0; m_FloatValue = 0; m_DoubleValue = 0; m_RationalValue = new CameraMetadataRational(); m_Type = NdkCameraMetadataType.Int64; m_LongValue = longValue; }
/// <summary> /// Constructs CameraMetadataValue using sbyte. This constructor only sets the sbyte field /// in the struct, leaving the rest of the data to default value. /// </summary> /// <param name="byteValue">The byte value set to the struct.</param> public CameraMetadataValue(sbyte byteValue) { m_IntValue = 0; m_LongValue = 0; m_FloatValue = 0; m_DoubleValue = 0; m_RationalValue = new CameraMetadataRational(); m_Type = NdkCameraMetadataType.Byte; m_ByteValue = byteValue; }
/// <summary> /// Constructs CameraMetadataValue using CameraMetadataRational. This constructor only sets the CameraMetadataRational field /// in the struct, leaving the rest of the data to default value. /// </summary> /// <param name="rationalValue">The CameraMetadataRational value set to the struct.</param> public CameraMetadataValue(CameraMetadataRational rationalValue) { m_ByteValue = 0; m_IntValue = 0; m_LongValue = 0; m_FloatValue = 0; m_DoubleValue = 0; m_Type = NdkCameraMetadataType.Rational; m_RationalValue = rationalValue; }
/// <summary> /// Constructs CameraMetadataValue using long. This constructor only sets the long field /// in the struct, leaving the rest of the data to default value. /// </summary> /// <param name="longValue">The long value set to the struct.</param> public CameraMetadataValue(long longValue) { _byteValue = 0; _intValue = 0; _floatValue = 0; _doubleValue = 0; _rationalValue = new CameraMetadataRational(); _type = NdkCameraMetadataType.Int64; _longValue = longValue; }
/// <summary> /// Constructs CameraMetadataValue using sbyte. This constructor only sets the sbyte field /// in the struct, leaving the rest of the data to default value. /// </summary> /// <param name="byteValue">The byte value set to the struct.</param> public CameraMetadataValue(sbyte byteValue) { _intValue = 0; _longValue = 0; _floatValue = 0; _doubleValue = 0; _rationalValue = new CameraMetadataRational(); _type = NdkCameraMetadataType.Byte; _byteValue = byteValue; }
/// <summary> /// Constructs CameraMetadataValue using CameraMetadataRational. This constructor only sets /// the CameraMetadataRational field in the struct, leaving the rest of the data to default /// value. /// </summary> /// <param name="rationalValue">The CameraMetadataRational value set to the struct.</param> public CameraMetadataValue(CameraMetadataRational rationalValue) { _byteValue = 0; _intValue = 0; _longValue = 0; _floatValue = 0; _doubleValue = 0; _type = NdkCameraMetadataType.Rational; _rationalValue = rationalValue; }
/** * \if english * @brief Construct a ARCameraMetadataValue using int. * @param intValue The int value set to the struct. * \else * @brief 使用int构建一个ARCameraMetadataValue。 * @param intValue 要使用的int值。 * \endif */ public ARCameraMetadataValue(int intValue) { m_ByteValue = 0; m_LongValue = 0; m_FloatValue = 0; m_DoubleValue = 0; m_RationalValue = new ARCameraMetadataRational(); m_Type = NdkCameraMetadataType.Int32; m_IntValue = intValue; }
private void LogError(NdkCameraMetadataType requestedType) { ARDebug.LogError("Error getting value from ARCameraMetadataType due to type mismatch. " + "requested type = {0}, internal type = {1}\n", requestedType, m_Type); }