Simulated Reality SDK 7500c78d v1.30.2.51085 2024-04-26T11:23:03Z
Stable
WeaverC.h
Go to the documentation of this file.
1
10#pragma once
11
12#include "WeaverTypes.h"
13
14#ifdef WIN32
15#ifdef __cplusplus
16# ifdef COMPILING_DLL_DimencoWeaving
17# define DIMENCOSR_API_C extern "C" __declspec(dllexport)
18# else
19# define DIMENCOSR_API_C extern "C" __declspec(dllimport)
20# endif
21#else
22# ifdef COMPILING_DLL_DimencoWeaving
23# error Trying to compile DimencoWeaving.dll using a non-C++ compiler! Use a C++ compiler instead!
24# else
25# define DIMENCOSR_API_C __declspec(dllimport)
26# endif
27#endif
28#else
29# define DIMENCOSR_API_C
30#endif
31
37
43DIMENCOSR_API_C void SetGlobalParametersFromConfig(const char* configPath, struct FLOAT3 userPos);
44
54DIMENCOSR_API_C enum WeaverErrorCode LoadTexture(enum WeaverTextureType type, unsigned char** out_pTexture, int* out_width, int* out_height, int* out_channels, int* out_bitsPerPixel);
55
60DIMENCOSR_API_C void UnLoadCorrectionTexture(unsigned char** in_pTexture);
61
62
64 struct FLOAT4* phases_offset, struct FLOAT4* phases_scale_x, struct FLOAT4* phases_scale_y,
65 struct FLOAT4* dxy_offset, struct FLOAT4* dxy_scale_x, struct FLOAT4* dxy_scale_y,
66 struct FLOAT2* ScreenPos_scale, struct FLOAT2* ScreenPos_offset_x, struct FLOAT2* ScreenPos_scale_y,
67 struct FLOAT2* WeaverVars_offset, struct FLOAT2* WeaverVars_scale_x, struct FLOAT2* WeaverVars_scale_y);
68
72
77
82
87
92
93#undef DIMENCOSR_API_C
DIMENCOSR_API_C void FillInterpolators(struct FLOAT2 TextureRes, struct FLOAT4 *phases_offset, struct FLOAT4 *phases_scale_x, struct FLOAT4 *phases_scale_y, struct FLOAT4 *dxy_offset, struct FLOAT4 *dxy_scale_x, struct FLOAT4 *dxy_scale_y, struct FLOAT2 *ScreenPos_scale, struct FLOAT2 *ScreenPos_offset_x, struct FLOAT2 *ScreenPos_scale_y, struct FLOAT2 *WeaverVars_offset, struct FLOAT2 *WeaverVars_scale_x, struct FLOAT2 *WeaverVars_scale_y)
DIMENCOSR_API_C void SetGlobalParametersFromConfig(const char *configPath, struct FLOAT3 userPos)
Set global shader parameters needed for weaving, using a different .ini file.
DIMENCOSR_API_C float GetPx()
Returns pitch in x direction in pixels.
DIMENCOSR_API_C void UnLoadCorrectionTexture(unsigned char **in_pTexture)
Unloads a texture.
DIMENCOSR_API_C float GetDoN()
Returns D over N in millimeters.
DIMENCOSR_API_C float GetSlant()
Returns slant as a coëfficiënt.
DIMENCOSR_API_C void SetGlobalParameters(struct FLOAT3 userPos)
Set global shader parameters needed for weaving.
#define DIMENCOSR_API_C
Definition: WeaverC.h:29
DIMENCOSR_API_C float GetN()
Returns the refractive index N.
DIMENCOSR_API_C float GetXTalkFactor()
DIMENCOSR_API_C float GetPattern()
DIMENCOSR_API_C float GetViewfilterSlope()
DIMENCOSR_API_C enum WeaverErrorCode LoadTexture(enum WeaverTextureType type, unsigned char **out_pTexture, int *out_width, int *out_height, int *out_channels, int *out_bitsPerPixel)
Fill the vertex attributes needed for weaving.
enum DIMENCOSR_API WeaverTextureType
Definition: WeaverTypes.h:22
enum DIMENCOSR_API WeaverErrorCode
Definition: WeaverTypes.h:27
Definition: WeaverTypes.h:34
Definition: WeaverTypes.h:45
Definition: WeaverTypes.h:53