标签:des style blog code http tar
{ { { { { { { { { { { { { { { { { { { { { { { { macroblock_type { { { { { { { { { { |
标签: Mpeg,数据格式 |
不知道这个东西怎么搞
该如何的提取下面的结构(不知道这样描述是不是正确) 请高手帮忙
要是北京的话 有时间请他吃水煮鱼 呵呵
Sector description
Offset Size Description
0x26 4 0x00, 0x00, 0x01, 0xbf – private stream header
0x2a 2 0x08, 0xe8 – data length
0x2c 2280 User data block
User data block
Offset Size Description
0x00 1 Block ID, from 0x11 to 0xf0
0x01 1 Block size in bytes
0x02 Block size Block data
1. Record time block (0x11)
Offset Size Description
0x00 1 0x11 – Block ID
0x01 1 0x06 – block length
0x02 1 year, offset from year 2000
0x03 1 month
0x04 1 date
0x05 1 hour
0x06 1 minute
0x07 1 second
2. User ID block (0x12)
Offset Size Description
0x00 1 0x12 – Block ID
0x01 1 0x40 – block length
0x02 64 User ID
3. Vehicle ID block (0x13)
Offset Size Description
0x00 1 0x13 – Block ID
0x01 1 0x40 – block length
0x02 64 Vehicle ID
4. Event information block(0x14)
Offset Size Description
0x00 1 0x14 – Block ID
0x01 1 0x44 – block length
0x02 4 Event status
0x06 40 Event information
5. Data block index block
Offset Size Description
0x00 1 0x15 – Block ID
0x01 1 N*5 – block length
0x02 1 Block1 type
0x03 4 Block1 offset
0x07 1 Block2 type
0x08 4 Block2 offset
… … …
2+N*5 1 Block N type
3+N*5 4 Block N offset
6. Route ID block (0x16)
Offset Size Description
0x00 1 0x16 – Block ID
0x01 1 0x40 – block length
0x02 64 Vehicle ID
7. Speed information block (0x17)
Offset Size Description
0x00 1 0x17 – Block ID
0x01 1 0x03 – block length
0x02 1 Speed low byte
0x03 1 Speed hi byte
0x04 1 0: KM/H 1: MPH
8. Display Information block (0x18)
Offset Size Description
0x00 1 0x18 – Block ID
0x01 1 0x45 – block length
0x02 1 Information ID, 0~31
0x03 2 X position
0x05 2 Y position
0x07 64 Information
9. GPS data information (0x19)
Offset Size Description
0x00 1 0x19 – Block ID
0x01 1 0x80 – block length
0x02 1 Information data length
0x03 128 Information
10. Route ID block (0x1a)
Offset Size Description
0x00 1 0x1a – Block ID
0x01 1 0x40 – block length
0x02 64 Vehicle ID
跟我一起学习 权当是 学习记录了
sequence header
this contains information related to one or more "group-of-pictures "
byte# data details
===================================================================
1-4 sequence header in hex 000001b3
code
12 bits horizontal size in pixels
12 bits vertical size in pixels
4 bits pel aspect ratio see below
18 bits picture rate see below
1 bit marker bit always 1
10 bits vbv buffer size minimum buffer needed to decode this
sequence of pictures; in 16kb units
1 bit constrained
parameter flag
1 bit load intra 0: false; 1: true (matrix follows)
quantizer matrix
64 bytes intra quantizer optional
matrix
1 bit load nonintra 0: false; 1: true (matrix follows)
quantizer matrix
64 bytes nonintra quantizer optional
matrix
- squence extension optional
data
- user data optional application-dependent data
===================================================================
aspect raios are defined by a code which represents the height and
width of the video image.
picture rates are also defined by a code that represents the number
of pictures that may be displayed each second.
each group of pictures has a header that contains one "i picture "
and zero or more b and p pictures. the header is concerned with
the time synchronisation for the first picture in this group, and
the closeness of the previous group to this one.
/*****************************************************************/
for picture rate:
1 = 23.976 frames/sec
2 = 24
3 = 25
4 = 29.97
5 = 30
6 = 50
7 = 59.94
8 = 60
here gives an example. below is hex dump of first 256 bytes of
the first video frame of test.mpg from xingmpeg.
00 00 01 b3 16 00 f0 c4 02 a3 20 a5 10 12 12 14
14 14 16 16 16 16 18 18 19 18 18 1a 1b 1b 1b 1b
1a 1c 1d 1e 1e 1e 1d 1c 1e 1f 20 21 21 20 1f 1e
21 23 23 24 23 23 21 25 26 27 27 26 25 29 2a 2a
2a 29 2d 2d 2d 2d 30 31 30 34 34 38 16 00 f0 c4
00 00 01 b8 00 08 00 00 00 00 01 00 00 0a 72 00
00 00 01 01 13 f9 50 02 bc b2 b8 be 68 8b a4 9f
c5 b5 ca 00 56 76 39 65 f2 30 8b a6 9d 50 69 e7
da fe 13 cf b7 ff 8f f4 ce 7b fa 0e f0 66 ae 1c
5d e7 00 c8 0a 92 b9 29 3c 21 23 f1 d6 40 13 06
f0 10 10 c6 27 80 a0 34 e1 c8 e4 0f 74 91 da c4
03 a0 dc 03 12 60 18 49 27 1d d4 bc 67 0e 54 8c
96 fc 5d c0 06 e0 1a 72 11 7c 9a 8d c9 45 89 6d
cd c4 0b 63 dc 90 18 24 00 ec 84 90 18 10 c9 3b
1e a7 60 3c 9d 74 80 76 05 0b 02 81 a9 29 39 68
53 8f 59 f1 bf 93 fb a0 04 01 bc b0 ce 18 e1 25
sequence header = (hex) 00 00 01 b3
horizontal size = 0x160 = 352
vertical size = 0x0f0 = 240
pel aspect ratio = [i don ‘t know]
picture rate = 4 = 29.97 frames/sec
marker bit = 1
标签:des style blog code http tar
原文地址:http://blog.csdn.net/mao0514/article/details/32326939