The..........PICTURE.....
AVI 파일 구조

THIS DOCUMENT IS IN THE PUBLIC DOMAIN, YOU ARE FREE TO COPY AND MODIFY IT AS YOU SEE FIT

BETA DOCUMENTATNION OF RIFF-AVI FILE FORMAT -- DO NOT TRUST FOR ACCURACY -- DOESN'T COVER OPENDML EXTENTIONS
YOU HAVE BEEN WARNED

Tree view of RIFF data chunks(ie. map of subchunks). LIST chunk will be added in next revision(the documentation I based this on didn't cover LIST chunks, oddly enough):

RIFF RIFF HEADER
|-AVI AVI CHUNK
..|-hdrl MAIN AVI HEADER
..|.|-avih AVI HEADER
..|.|-strl STREAM LIST[One per stream]
..|.|.|-strh STREAM HEADER[Requiered after above]
..|.|.|-strf STREAM FORAMT
..|.|.|-strd OPTIONAL -- STREAM DATA
..|.|.|-strn OPTIONAL -- STREAM NAME
..|-movi MOVIE DATA
..|.|-rec RECORD DATA[SEE BELOW]
..|...|-[data subchunks] RAW DATA[SEE BELOW]
..|-idx1 AVI INDEX
....|-[index data] DATA


DATA Map(ie sequential listing of all the data contained in the various chunks):

"RIFF"
dwChunkSize; - Chunk Size in Bytes
"AVI "
dwAVIChunkSize; - AVI chunk size
"LIST"
dwLIST1ChunkSize; - LIST chunk size
"hdrl"
"avih"
dwMicroSecPerFrame; - Specifies the number of microseconds between frames. This value indicates the overall timing for the file.
dwMaxBytesPerSec; - Specifies the approximate maximum data rate of the file. This value indicates the number of bytes per second the system must handle to present an AVI sequence as specified by the other parameters contained in the main header and stream header chunks.
dwReserved1; - set to 0, reserved
dwFlags; - [Bit 4 - Has index(idx1), Bit 5 - Use index to determine how to read the AVI data, rather than the physical order of the chunks with the RIFF file, Bit 8 - AVI file is interleaved, Bit 16 - AVI file is optimized for live video capture, Bit 17 - AVI file contains copyrighted data]
dwTotalFrames; - Total number of frames
dwInitialFrames; - Specifies the initial frame for interleaved files. Noninterleaved files should specify zero. If you are creating interleaved files, specify the number of frames in the file prior to the initial frame of the AVI sequence in this member. For more information about the contents of this member, see "Special Information for Interleaved Files" in the Video for Windows Programmer's Guide.
dwStreams; - Specifies the number of streams in the file. For example, a file with audio and video has two streams.
dwSuggestedBufferSize; - Specifies the suggested buffer size for reading the file. Generally, this size should be large enough to contain the largest chunk in the file. If set to zero, or if it is too small, the playback software will have to reallocate memory during playback, which will reduce performance. For an interleaved file, the buffer size should be large enough to read an entire record, and not just a chunk.
dwWidth; - Specifies the width of the AVI file in pixels.
dwHeight; - Specifies the height of the AVI file in pixels.
dwReserved[4]; - Reserved, set this array to 0
"LIST"
dwLISTChunkSize; - size of second LIST chunk
"strl"
"strh"
dwstrhSize; - size of strh
fccType; - FourCC code for type of data contained in this stream - 'auds' = audio stream, 'mids' = MIDI stream, 'txts' = Text stream, 'vids' = Video sterm
fccHandler; - FourCC of codec to use, for PVDTools this should be "DIB " or "Y8 " or "Y800" or "GREY" and eventually "Y4 "
dwFlags; - Ignore, too little documentation
wPriority; - Ignore
wLanguage; - Ignore
dwInitialFrames; - "How far audio data is skewed ahead of video frames in interleaved file."
dwScale; - "Used with dwRate(see below) to specify the time scale that this stream will use." Divide dwRate by dwScale to get frame rate/sample rate
dwRate; - See dwScale
dwStart; - "Specifies starting time for this stream." Usually 0.
dwLength; - Length of stream in units specified by dwRate and dwScale
dwSuggestedBufferSize; - Ignore
dwQualty; - Ignore
dwSampleSize; - Sample size, zero if varies - same a nBlockAlign in WAVEFORAMTEX
rcFrame; - RECT structure(struct of 4 shorts), ignore
"strf" - same format as BITMAPINFO
[strf stuff]
"LIST
dwLISTSize3; - Size of 3rd List chunk
"strl"
"strh"
size of strh
"auds"
above strh format
[typically a "JUNK" chunk goes here wehn using VirtualDub 1.5.xx or higher]
"LIST"
size of 4th LIST chunk(DWORD)
"01xx" -- ignore the xx, it's useless[the 01 stands for second stream identified in header]
[audio data]
"00xx" -- ignore the xx, it's useless[the 00 stands for first stream identified in header]
[video data]AviFormat.txt
[rinse, repeat the 01xx and 00xx chunks as needed]
"idx1"
size of idx1 chunk
chunkId
flags
offset of chunk
size of chunk
[rinse, repeat for each chunk of data]
"JUNK"
[blank info]

출처 : http://pvdtools.sourceforge.net/

이 글과 관련있는 글을 자동검색한 결과입니다 [?]

by 희돌군 | 2009/06/26 12:49 | 컴퓨터-Programming | 트랙백 | 덧글(1)
트랙백 주소 : http://glintist.egloos.com/tb/2381487
☞ 내 이글루에 이 글과 관련된 글 쓰기 (트랙백 보내기) [도움말]
Commented by 푸른나무 at 2009/06/26 14:10
이번엔 무슨 프로젝트 하려고? ㅎ

:         :

:

비공개 덧글






◀ 이전 페이지 다음 페이지 ▶



-사진인생- 세번째 이야기
by 희돌군
메뉴릿
최근 등록된 덧글
링크만 걸어놨습니다 :)
by hks9999 at 10/28
퍼 가겠습니다 ^^ ..
by hks9999 at 10/28
믿고 사는 세상을 위해..
by 희돌군 at 10/28
마지막 하트 사진과 ..
by 푸른나무 at 10/28
'아 어떡해' 하고 '빵공..
by 푸른나무 at 10/28
여자친구 생겼냐
by 베라모드 at 10/28
좋은 글 감사히 보고 ..
by MainBuU at 10/22
글쎄요~ ㅋㅋ 가긴 혼..
by 희돌군 at 10/21
8월 25일쯤에.. 아마도~
by 희돌군 at 10/21
ㅎ ㅔ ㅎ ㅔ ~~ 놀러 ..
by 희돌군 at 10/21
카테고리
전체
☆끄적☆
☆삽질☆
☆군대☆
☆낚시☆
☆사진☆
☆느낌☆
☆컴공부☆
☆취미☆
전북대학교
멤버십
불가리아
컴퓨터-Windows
컴퓨터-Linux
컴퓨터-Programming
컴퓨터-Database
컴퓨터-Web
컴퓨터-iPod
미분류
최근 등록된 트랙백
Directshow : IBasic..
by PPang Community
내 별 찾기
by He is fond of sweet..
Best gambling onlin..
by Online casino gamb..
Online gambling re..
by Online gambling re..
Online gambling.
by History of gambling.
넌 그러하냐 난 이러하다.
by input[0] = Meat; i..
포토로그
메모장
이글루링크
He is fond of sweet..
푸른나무그늘
병든 냥이의 외로운 거..
일상.
까망군
BLUE DEVILS 한 여..
작은별님의 이글루
이글루 파인더
태그
windowmobile 미를친헌재 mssql 복구 dialog 미친헌재 부트로더 헌재 thread iphone MonoProject put_Volume 부산여행 아이팟 데시벨 윈도우즈 iPod_App Slider 아이팟개발 windows 별자리 리눅스 모노 ms-sql Mono PlatformNotSupportedException mfc 설치 IBasicAudio ipod
rss

skin by teatime