参数名 参数类型 参数说明
period_num int 行扫周期(小周期)数,范围0~128
pwm_gclk_num int 行扫灰阶,范围0~1024,并且period_num*pwm_gclk_num <=65536
gamma float gamma指数值
GammaOutput int* 返回gamma表,返回值<65536
---------------------------------------------------------------------
函数调用举例
#include <iostream>
#include <Windows.h>
typedef int (*FUN)(int *,int,int,float);
int main()
{
std::cout << "Hello World!\n";
FUN mydll=NULL;
HINSTANCE hdll = LoadLibraryA("dll1.dll");
if (hdll == NULL)
{
return 0;
}
mydll = (FUN)GetProcAddress(hdll, "GammaV2_Variable_BitWidth_Exponent");
if (mydll == NULL)
{
FreeLibrary(hdll);
return 0;
}
int i;
int period_num = 64;//行扫周期(小周期)数
int pwm_gclk_num = 128;//行扫灰阶
float gamma = 2.8;//指数值
int *GammaOutput;
GammaOutput=new int[256];
mydll(GammaOutput, period_num, pwm_gclk_num, gamma);
for (i = 0; i < 256; i = i + 1) {
printf("%d\n", GammaOutput[i]);
}
std::cout << "end\n";
}