Operator Library: Color
運算子 BAYER3x3Linear 從 Bayer 輸入影像重建 RGB 影像。 從技術上講,Bayer Raw 影像是由交替的紅色、綠色和藍色像素組成的灰階影像。 BAYER3x3Linear 透過雙線性重建從 Bayer 相機取得 RGB 影像。 輸入 link 必須是 Bayer 影像的 3x3 核心。
運算子輸入為灰階影像,而輸出為彩色影像。 因此,輸出 Bit Width 增加三倍加上每個元件 2 個精度位元。 例如,8 bit 灰階輸入影像將被重建為 3 * (8 + 2) bit 彩色影像。 如果不需要新增的精度位元,可以使用運算子 RND 或 ShiftRight 將其捨棄。
The Bayer array configuration of the camera must match the operator settings. The operator setting is changed using parameter BayerInit. Four different mappings of the Bayer array on the sensor are possible:
-
GreenFollowedByRed

-
RedFollowedByGreen

-
BlueFollowedByGreen

-
GreenFollowedByBlue

圖中顯示的是傳輸至幀擷取卡的影像左上角。 一般而言,此處即為相機感光元件的左上角,但若您在 相機中設定了感興趣區域,此位置可能會有所變化。 感光元件的像素上疊加了圖中所示的四種不同拜耳陣列之一。 請選擇與您的相機影像感測器相對應的拜耳圖案。
底層演算法無專利權限制。
| Link Parameter | Input Link I | Output Link O |
|---|---|---|
| Bit Width | [1, 19] | (InputBitWidth + 2) * 3 |
| Arithmetic | unsigned | as I |
| Parallelism | any | as I |
| Kernel Columns | 3 | 1 |
| Kernel Rows | 3 | 1 |
| Img Protocol | {VALT_IMAGE2D, VALT_LINE1D} | as I |
| Color Format | VAF_GRAY | VAF_COLOR |
| Color Flavor | FL_NONE | FL_RGB |
| Max. Img Width | any | as I |
| Max. Img Height | any | as I |
| BayerInit | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | GreenFollowedByRed |
| Range | {GreenFollowedByRed, GreenFollowedByBlue, RedFollowedByGreen, BlueFollowedByGreen} |
|
The Bayer array configuration of the camera match the operator settings. See descriptions above. |
|
以下範例顯示了運算子 BAYER3x3Linear 的使用方式:
-
範例 - 此範例展示使用 3x3 濾波器進行 Bayer RAW 模式的去馬賽克(demosaicing)。
-
「Bayer 3x3 Demosacing with White Balancing」
範例 - 此範例展示使用 3x3 濾波器進行 Bayer RAW 模式的去馬賽克。 此外,還加入了用於色彩校正的白平衡。
-
「Image Received: Event Generation and General Purpose Output (GPO)」
範例 - 此範例顯示了影像影格開始與結束的訊號及事件產生。

上一頁

