9 Data Streams (データストリーム)
9.4 Image Streams (画像ストリーム)
9.4.6 Rectangular Image Stream (矩形画像ストリーム)
9.4.6.2 Rectangular Image Header (矩形画像のヘッダ)
The header contains critical information needed by the Host to decode succeeding image line data. The contents of the header are therefore redundantly encoded to allow proper decoding in case of a single bit error during transmission.
The image header shall be as shown in Table 38.
Table 38 ― Rectangular image header
Word Content Description
1 4x K28.3 Stream Marker.
2 4x 0x01 Rectangular Image Header indication.
3 4x StreamID Unique stream ID.
4 4x SourceTag(15:8) 5 4x SourceTag (7:0)
16 bit source image index. Incremented for each transferred image, wraparound to 0 at 0xFFFF. The same number shall be used by each stream containing data relating to the same image.
6 4x Xsize(23:16) 7 4x Xsize(15:8) 8 4x Xsize(7:0)
24 bit value representing the image width in pixels.
9 4x Xoffs(23:16) 10 4x Xoffs(15:8) 11 4x Xoffs(7:0)
24 bit value representing the horizontal offset in pixels of the image with respect to the left hand pixel of the full Device image.
Comment: Xoffs and Yoffs tell the Host where this image is with respect to the full Device image size.
12 4x Ysize(23:16) 13 4x Ysize(15:8) 14 4x Ysize(7:0)
24 bit value representing the image height in pixels.
This value shall be set to 0 for line scan images.
15 4x Yoffs(23:16) 16 4x Yoffs(15:8) 17 4x Yoffs(7:0)
24 bit value representing the vertical offset in pixels of the image with respect to the top line of the full Device image.
This value shall be set to 0 for line scan images.
Comment: Xoffs and Yoffs tell the Host where this image is with respect to the full Device image size. As it represents the full Device image, it is the same for both fields of an interlaced image.
18 4x DsizeL(23:16) 19 4x DsizeL(15:8) 20 4x DsizeL(7:0)
24 bit value representing the number of data words per image line.
continued on next page …
Word Content Description 21 4x PixelF(15:8)
22 4x PixelF(7:0)
16 bit value representing the pixel format (see section 9.4.1).
23 4x TapG(15:8) 24 4x TapG(7:0)
16 bit value representing the tap geometry (see section 9.4.5).
25 4x Flags Image flags: (8 bits, repeated 4 times) Bits: Usage:
1:0 Interlacing:
0x0 None (Progressive scan or line scan) 0x1 Interlaced, first line after header from field 1 * 0x2 Interlaced, first line after header from field 2 0x3 Reserved for future use
7:2 Reserved for future use, set to 0
* Field 1 is defined as the field that includes the top image line.
Figure 29 ― Example 8x8 ROI in a VGA sized sensor
Full sensor size Xoffs
Full sensor size Yoffs 0 1 2 3 4 5
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Xsize
638 639 20
6 7 8 9 10 11 12 13
Ysize
14
478 479
ヘッダはホストが連続した画像ラインデータをデコードするのに必要な重要情報を含んでいる。伝送中にシングル ビットエラーが発生した場合にも正しいデコードを可能にするため,ヘッダの内容は冗長エンコードされる。
画像ヘッダは表 38に示す内容にて構成すること<SHALL>。
表 38 ― 矩形画像ヘッダ
ワード 内容 説明
1 4×K28.3 ストリームマーカ
2 4×0x01 矩形画像ヘッダのフラグ
3 4×StreamID ユニークなストリームID
4 4×SourceTag(15:8) 5 4×SourceTag (7:0)
16bit で表されるソース画像インデックス。各伝送画像毎に0~0xFFFF の範 囲でインクリメントされる。同じ画像に関係するデータが含まれるストリームに は同じ数を使用すること<SHALL>。
6 4×Xsize(23:16) 7 4×Xsize(15:8) 8 4×Xsize(7:0)
24bitで表される矩形画像の水平画素数
9 4×Xoffs(23:16) 10 4×Xoffs(15:8) 11 4×Xoffs(7:0)
24bitで表される全デバイス画像の左端を基点とした矩形画像の水平オフセ ット画素数
コメント: XoffsとYoffsはホストに全デバイス画像サイズに対してこの矩形画 像がどこに位置するかという情報を伝える。
12 4×Ysize(23:16) 13 4×Ysize(15:8) 14 4×Ysize(7:0)
4bitで表される画像の垂直画素数
ラインスキャン画像のときは0 を設定すること<SHALL>。
15 4×Yoffs(23:16) 16 4×Yoffs(15:8) 17 4×Yoffs(7:0)
24bitで表される全デバイス画像の上端を基点とした矩形画像の垂直オフセ ット画素数
ラインスキャン画像のときは0 を設定すること<SHALL>。
コメント: XoffsとYoffsはホストに全デバイス画像サイズに対してこの矩形画 像がどこに位置するかという情報を伝える。矩形画像が全デバイス画像と同じ 場合は,インターレース画像の両フィールドでも同じオフセットとなる。
18 4×DsizeL(23:16) 19 4×DsizeL(15:8) 20 4×DsizeL(7:0)
24bitで表される画像ライン毎のデータワード数
次ページに続く
ワード 内容 説明 21 4×PixelF(15:8)
22 4×PixelF(7:0)
16bitで表されるピクセルフォーマット(セクション9.4.1参照)。
23 4×TapG(15:8) 24 4×TapG(7:0)
16bitで表されるタップジオメトリ(セクション9.4.5参照)。
25 4×Flags 画像フラグ(8 bit, 4回繰り返し)
ビット範囲 割り当て: 1:0 インターレース化 0x0 ノンインターレース
(プログレッシブスキャンまたはラインスキャン)
0x1 インターレース,
フィールド1* のヘッダの後に最初のラインが来る 0x2 インターレース,
フィールド2のヘッダの後に最初のラインが来る 0x3 将来的な使用のための予約
7:2 予約,0に設定する
*フィールド 1 は画像の開始ラインを含むフィールドとして定義される。
図 29 ― VGAサイズのセンサにおける8×8 ROIの例
センサの全サイズ Xoffs
センサの全サイズ Yoffs
0 1 2 3 4 5
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Xsize
638 639 20
6 7 8 9 10 11 12 13
Ysize
14
478 479