//可基于相机的彩色类型、分辨率来确定 可变参数TY_IMAGE_MODE_BAYER8GB_1280x960
TYSetEnum(hDevice, TY_COMPONENT_RGB_CAM, TY_ENUM_IMAGE_MODE, TY_IMAGE_MODE_BAYER8GB_1280x960);
TYSetInt(hDevice, TY_COMPONENT_RGB_CAM, TY_INT_ANALOG_GAIN, 4);
TYSetInt(hDevice, TY_COMPONENT_RGB_CAM, TY_INT_EXPOSURE_TIME, value);
TYSetInt(hDevice, TY_COMPONENT_IR_CAM_LEFT, TY_INT_GAIN,value);
TYSetBool(hDevice, TY_COMPONENT_IR_CAM_LEFT, TY_BOOL_UNDISTORTION, true);
//基于相机分辨率来设定对应的
TYSetEnum(hDevice, TY_COMPONENT_DEPTH_CAM, TY_ENUM_IMAGE_MODE, TY_IMAGE_MODE_DEPTH16_640x480);
TYSetBool(hDevice, TY_COMPONENT_IR_CAM_RIGHT, TY_BOOL_UNDISTORTION, true);
TYSetBool(hDevice, TY_COMPONENT_LASER, TY_BOOL_LASER_AUTO_CTRL, true);
//设置前关闭自动开关
TYSetInt(hDevice, TY_COMPONENT_LASER, TY_INT_LASER_POWER, value);
TYSetBool(hDevice, TY_COMPONENT_DEVICE, TY_BOOL_KEEP_ALIVE_ONOFF, false);
//2000-30000,单位:毫秒。默认15s
TYSetInt(hDevice, TY_COMPONENT_DEVICE, TY_INT_KEEP_ALIVE_TIMEOUT, value);
TY_TRIGGER_PARAM trigger;
trigger.mode = TY_TRIGGER_MODE_OFF;
ASSERT_OK(TYSetStruct(hDevice, TY_COMPONENT_DEVICE, TY_STRUCT_TRIGGER_PARAM, &trigger,sizeof(trigger)));
TYSetEnum(hDevice, TY_COMPONENT_DEVICE, TY_ENUM_STREAM_ASYNC, TY_STREAM_ASYNC_ALL);
//上升沿
TYSetEnum(hDevice, TY_COMPONENT_DEVICE, TY_ENUM_TRIGGER_POL, TY_TRIGGER_POL_RISINGEDGE);
//下降沿
TYSetEnum(hDevice, TY_COMPONENT_DEVICE, TY_ENUM_TRIGGER_POL, TY_TRIGGER_POL_FALLINGEDGE);
TYGetInt(hDevice, TY_COMPONENT_DEVICE, TY_INT_CAPTURE_TIME_US, &capture_time)