Acquisition Frame Rate (dart E)#
如果您想在自由執行影像擷取中以固定的影格率操作相機,這將非常有用。
使用功能#
運作原理#
如果啟用了 Acquisition Frame Rate 功能,相機的最大影格速率將受限於您為 acquisition frame rate 參數所輸入的值。
例如,將 acquisition frame rate 設定為每秒 20 個影格 (fps) 會產生以下效果:
- 如果限制影格率的其他因素允許大於 20 fps 的影格率,則影格率將維持在 20 fps 的固定影格率。
- 如果其他限制影格速率的因素僅允許 小於 20 fps 的影格速率,則 Acquisition Frame Rate 功能不會影響該影格速率。
設定 Acquisition Frame Rate#
- 將相機中的
AcquisitionFrameRateEnable參數設為true(若適用)。 - 將相機中的
AcquisitionFrameRate將參數設為相機影格速率(以每秒影格數計)所需的上限。
詳細資料#
| 相機型號 | AcquisitionFrameRateEnable 參數可用 |
|---|---|
| daA2500-60mc | 否 |
| daA2500-60mci | 是 |
| daA3840-30mc | 不支援 Acquisition Frame Rate 功能 |
| daA4200-30mci | 是 |
範例程式碼#
/* Macro to check for errors */
#define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc)
GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */
/* Set the upper limit of the camera's frame rate to 30 fps */
errRes = PylonDeviceSetBooleanFeature(hdev, "AcquisitionFrameRateEnable", 1);
CHECK(errRes);
errRes = PylonDeviceSetFloatFeature(hdev, "AcquisitionFrameRate", 30.0);
CHECK(errRes);
/* Macro to check for errors */
#define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc)
GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */
/* Set the upper limit of the camera's frame rate to 30 fps */
errRes = PylonDeviceSetBooleanFeature(hdev, "AcquisitionFrameRateEnable", 1);
CHECK(errRes);
errRes = PylonDeviceSetFloatFeature(hdev, "AcquisitionFrameRate", 30.0);
CHECK(errRes);
您也可以使用 pylon Viewer 輕鬆設定參數。