Varjo Native SDK
Varjo_mr.h
Go to the documentation of this file.
1 // Copyright 2019-2020 Varjo Technologies Oy. All rights reserved.
2 
3 #ifndef VARJO_MR_H
4 #define VARJO_MR_H
5 
6 #include "Varjo_export.h"
7 #include "Varjo_types.h"
8 #include "Varjo_types_mr.h"
9 
10 #if defined __cplusplus
11 extern "C" {
12 #endif
13 
39 VARJO_API varjo_Bool varjo_Lock(struct varjo_Session* session, varjo_LockType lockType);
40 
58 VARJO_API void varjo_Unlock(struct varjo_Session* session, varjo_LockType lockType);
59 
71 VARJO_API void varjo_MRSetVideoRender(struct varjo_Session* session, varjo_Bool enabled);
72 
91 VARJO_API void varjo_MRSetVideoDepthEstimation(struct varjo_Session* session, varjo_Bool enabled);
92 
115 VARJO_API void varjo_MRSetVRViewOffset(struct varjo_Session* session, double percentage);
116 
128 VARJO_API void varjo_MRSetChromaKey(struct varjo_Session* session, varjo_Bool enabled);
129 
152 
165 VARJO_DEPRECATED_API void varjo_MRUnlockChromaKeyConfig(struct varjo_Session* session);
166 
176 VARJO_API int32_t varjo_MRGetChromaKeyConfigCount(struct varjo_Session* session);
177 
193 VARJO_API void varjo_MRSetChromaKeyConfig(struct varjo_Session* session, int32_t index, const struct varjo_ChromaKeyConfig* config);
194 
206 VARJO_API struct varjo_ChromaKeyConfig varjo_MRGetChromaKeyConfig(struct varjo_Session* session, int32_t index);
207 
234 
247 VARJO_DEPRECATED_API void varjo_MRUnlockCameraConfig(struct varjo_Session* session);
248 
259 VARJO_API int32_t varjo_MRGetCameraPropertyModeCount(struct varjo_Session* session, varjo_CameraPropertyType prop);
260 
277 VARJO_API void varjo_MRGetCameraPropertyModes(struct varjo_Session* session, varjo_CameraPropertyType prop, varjo_CameraPropertyMode* modes, int32_t maxSize);
278 
291 
307 VARJO_API void varjo_MRSetCameraPropertyMode(struct varjo_Session* session, varjo_CameraPropertyType type, varjo_CameraPropertyMode mode);
308 
324 
335 VARJO_API int32_t varjo_MRGetCameraPropertyValueCount(struct varjo_Session* session, varjo_CameraPropertyType prop);
336 
366  struct varjo_Session* session, varjo_CameraPropertyType prop, struct varjo_CameraPropertyValue* values, int32_t maxSize);
367 
379 VARJO_API struct varjo_CameraPropertyValue varjo_MRGetCameraPropertyValue(struct varjo_Session* session, varjo_CameraPropertyType type);
380 
397 VARJO_API void varjo_MRSetCameraPropertyValue(struct varjo_Session* session, varjo_CameraPropertyType type, const struct varjo_CameraPropertyValue* value);
398 
411 VARJO_API void varjo_MRResetCameraProperty(struct varjo_Session* session, varjo_CameraPropertyType type);
412 
424 VARJO_API void varjo_MRResetCameraProperties(struct varjo_Session* session);
425 
426 #if defined __cplusplus
427 }
428 #endif
429 #endif // VARJO_MR_H
varjo_MRGetChromaKeyConfigCount
int32_t varjo_MRGetChromaKeyConfigCount(struct varjo_Session *session)
Get number of chroma key config indices supported.
varjo_MRGetCameraPropertyValues
void varjo_MRGetCameraPropertyValues(struct varjo_Session *session, varjo_CameraPropertyType prop, struct varjo_CameraPropertyValue *values, int32_t maxSize)
Get possible manual property values.
varjo_MRSetCameraPropertyValue
void varjo_MRSetCameraPropertyValue(struct varjo_Session *session, varjo_CameraPropertyType type, const struct varjo_CameraPropertyValue *value)
Sets manual property value.
varjo_CameraPropertyValue::value
union varjo_CameraValue value
Value union. Determine from 'type' which element to access.
Definition: Varjo_types_mr.h:109
Varjo_export.h
varjo_ChromaKeyConfig::type
varjo_ChromaKeyType type
Chroma key type.
Definition: Varjo_types_mr.h:51
varjo_MRGetCameraPropertyValueCount
int32_t varjo_MRGetCameraPropertyValueCount(struct varjo_Session *session, varjo_CameraPropertyType prop)
Get amount of possible manual camera property values.
varjo_CameraPropertyType
int64_t varjo_CameraPropertyType
Camera property types that can be accessed to control video pass through cameras.
Definition: Varjo_types_mr.h:78
varjo_MRGetCameraPropertyValue
struct varjo_CameraPropertyValue varjo_MRGetCameraPropertyValue(struct varjo_Session *session, varjo_CameraPropertyType type)
Returns the latest manual property value set with varjo_MRSetCameraPropertyValue for the given proper...
varjo_MRSetVideoDepthEstimation
void varjo_MRSetVideoDepthEstimation(struct varjo_Session *session, varjo_Bool enabled)
Start depth estimation for the video pass through image.
varjo_MRLockChromaKeyConfig
VARJO_DEPRECATED_API varjo_Bool varjo_MRLockChromaKeyConfig(struct varjo_Session *session)
Try to lock the chroma key configuration.
varjo_Bool
int32_t varjo_Bool
Definition: Varjo_types.h:135
varjo_CameraPropertyConfigType
int64_t varjo_CameraPropertyConfigType
Camera property config type.
Definition: Varjo_types_mr.h:61
varjo_MRGetChromaKeyConfig
struct varjo_ChromaKeyConfig varjo_MRGetChromaKeyConfig(struct varjo_Session *session, int32_t index)
Get currently applied chroma keying configuration for given index.
varjo_MRGetCameraPropertyModeCount
int32_t varjo_MRGetCameraPropertyModeCount(struct varjo_Session *session, varjo_CameraPropertyType prop)
Get amount of camera property modes.
varjo_CameraPropertyValue::type
varjo_CameraPropertyDataType type
Data type for this value.
Definition: Varjo_types_mr.h:108
varjo_MRUnlockCameraConfig
VARJO_DEPRECATED_API void varjo_MRUnlockCameraConfig(struct varjo_Session *session)
Unlock previously locked camera configuration.
varjo_MRGetCameraPropertyModes
void varjo_MRGetCameraPropertyModes(struct varjo_Session *session, varjo_CameraPropertyType prop, varjo_CameraPropertyMode *modes, int32_t maxSize)
Get available property modes.
Varjo_types_mr.h
varjo_Lock
varjo_Bool varjo_Lock(struct varjo_Session *session, varjo_LockType lockType)
Try to lock the given lock type.
varjo_MRGetCameraPropertyMode
varjo_CameraPropertyMode varjo_MRGetCameraPropertyMode(struct varjo_Session *session, varjo_CameraPropertyType type)
Returns currently set mode for given property type.
Varjo_types.h
varjo_MRSetChromaKey
void varjo_MRSetChromaKey(struct varjo_Session *session, varjo_Bool enabled)
Start chroma keying for the video pass through image.
varjo_MRLockCameraConfig
VARJO_DEPRECATED_API varjo_Bool varjo_MRLockCameraConfig(struct varjo_Session *session)
Try to lock the camera configuration.
varjo_MRSetChromaKeyConfig
void varjo_MRSetChromaKeyConfig(struct varjo_Session *session, int32_t index, const struct varjo_ChromaKeyConfig *config)
Set video chroma keying configuration to select color matcher and setting parameters for it.
varjo_ChromaKeyConfig
Chroma key config structure including type info and actual parameters.
Definition: Varjo_types_mr.h:50
varjo_MRSetVideoRender
void varjo_MRSetVideoRender(struct varjo_Session *session, varjo_Bool enabled)
Start video pass through rendering on the HMD displays.
varjo_MRSetCameraPropertyMode
void varjo_MRSetCameraPropertyMode(struct varjo_Session *session, varjo_CameraPropertyType type, varjo_CameraPropertyMode mode)
Sets property mode.
varjo_MRResetCameraProperty
void varjo_MRResetCameraProperty(struct varjo_Session *session, varjo_CameraPropertyType type)
Resets the camera property mode and manual mode value to defaults.
varjo_MRResetCameraProperties
void varjo_MRResetCameraProperties(struct varjo_Session *session)
Resets all camera properties to the default mode and value.
varjo_MRSetVRViewOffset
void varjo_MRSetVRViewOffset(struct varjo_Session *session, double percentage)
Change virtual camera rendering position between users eyes and video pass through cameras.
varjo_Unlock
void varjo_Unlock(struct varjo_Session *session, varjo_LockType lockType)
Unlock a previously locked lock.
VARJO_DEPRECATED_API
#define VARJO_DEPRECATED_API
Definition: Varjo_export.h:30
varjo_CameraPropertyMode
int64_t varjo_CameraPropertyMode
Camera property modes that can be set to control video pass through cameras.
Definition: Varjo_types_mr.h:90
varjo_CameraPropertyValue
Camera property value structure including type info and actual value.
Definition: Varjo_types_mr.h:107
varjo_MRUnlockChromaKeyConfig
VARJO_DEPRECATED_API void varjo_MRUnlockChromaKeyConfig(struct varjo_Session *session)
Unlock previously locked chroma key configuration.
varjo_MRGetCameraPropertyConfigType
varjo_CameraPropertyConfigType varjo_MRGetCameraPropertyConfigType(struct varjo_Session *session, varjo_CameraPropertyType prop)
Get manual property config type for given property.
varjo_LockType
int64_t varjo_LockType
Mixed reality lock types.
Definition: Varjo_types_mr.h:17