欢迎来到淘文阁 - 分享文档赚钱的网站! | 帮助中心 好文档才是您的得力助手!
淘文阁 - 分享文档赚钱的网站
全部分类
  • 研究报告>
  • 管理文献>
  • 标准材料>
  • 技术资料>
  • 教育专区>
  • 应用文书>
  • 生活休闲>
  • 考试试题>
  • pptx模板>
  • 工商注册>
  • 期刊短文>
  • 图片设计>
  • ImageVerifierCode 换一换

    2022年avi格式 .pdf

    • 资源ID:27250304       资源大小:94.48KB        全文页数:13页
    • 资源格式: PDF        下载积分:4.3金币
    快捷下载 游客一键下载
    会员登录下载
    微信登录下载
    三方登录下载: 微信开放平台登录   QQ登录  
    二维码
    微信扫一扫登录
    下载资源需要4.3金币
    邮箱/手机:
    温馨提示:
    快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
    如填写123,账号就是123,密码也是123。
    支付方式: 支付宝    微信支付   
    验证码:   换一换

     
    账号:
    密码:
    验证码:   换一换
      忘记密码?
        
    友情提示
    2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
    3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
    4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
    5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

    2022年avi格式 .pdf

    AVI Files The Microsoft Audio/Video Interleaved (AVI) file format is a RIFF file specification used with applications that capture, edit, and playback audio/video sequences. In general, AVI files contain multiple streams of different types of data. Most AVI sequences will use both audio and video streams. A simple variation for an AVI sequence uses video data and does not require an audio stream. Specialized AVI sequences might include a control track or MIDI track as an additional data stream. The control track could control external devices such as an MCI videodisc player. The MIDI track could play background music for the sequence. While a specialized sequence requires a specialized control program to take advantage of all its capabilities, applications that can read and play AVI sequences can still read and play an AVI sequence in a specialized file. (These applications ignore the non-AVI data in the specialized file.) This chapter primarily describes AVI files containing only audio and video data. This chapter covers the following topics: ?The required chunks of an AVI file ?The optional chunks of an AVI file ?Developing routines to write AVI files For additional information about RIFF files, see the Microsoft Windows Multimedia Programmers Guide and Microsoft Windows Multimedia Programmers Reference. For additional information about installable compressors and decompressors, see chapter 10, Video Compression and Decompression Drivers. AVI RIFF Form AVI files use the AVI RIFF form. The AVI RIFF form is identified by the four-character code AVI . All AVI files include two mandatory LIST chunks. These chunks define the format of the streams and stream data. AVI files might also include an index chunk. This optional chunk specifies the location of data chunks within the file. An AVI file with these components has the following form: RIFF (AVI LIST (hdrl . . . ) LIST (movi . . . ) idx1 ) The LIST chunks and the index chunk are subchunks of the RIFF AVI chunk. The AVI chunk identifies the file as an AVI RIFF file. The LIST hdrl chunk defines the format of the data and is the first required list chunk. The LIST movi chunk contains the data for the AVI sequence and is the second required list chunk. The idx1 chunk is the optional index chunk. AVI files must keep these three components in the proper sequence. The LIST hdrl and LIST movi chunks use subchunks for their data. The following example shows the AVI RIFF form expanded with the chunks needed to complete the LIST hdrl and LIST movi chunks: RIFF (AVI LIST (hdrl avih() LIST (strl strh() 名师资料总结 - - -精品资料欢迎下载 - - - - - - - - - - - - - - - - - - 名师精心整理 - - - - - - - 第 1 页,共 13 页 - - - - - - - - - strf() strd(additional header data) . . . ) . . . ) LIST (movi SubChunk | LIST(rec SubChunk1 SubChunk2 . . . ) . . . . . . ) idx1 ) The following sections describe the chunks contained in the LIST hdrl and LIST movi chunks as well as the idx1 chunk. Data Structures for AVI Files Data structures used in the RIFF chunks are defined in the AVIFMT.H header file. The reference section at the end of this chapter describes the data structures that can be used for the main AVI header, stream header, AVIIndex, and palette change chunks. The Main AVI Header LIST The file begins with the main header. In the AVI file, this header is identified with avih four-character code. The header contains general information about the file, such as the number of streams within the file and the width and height of the AVI sequence. The main header has the following data structure defined for it: typedef struct DWORD dwMicroSecPerFrame; DWORD dwMaxBytesPerSec; DWORD dwReserved1; DWORD dwFlags; DWORD dwTotalFrames; DWORD dwInitialFrames; DWORD dwStreams; DWORD dwSuggestedBufferSize; DWORD dwWidth; DWORD dwHeight; DWORD dwScale; DWORD dwRate; DWORD dwStart; DWORD dwLength; MainAVIHeader; 名师资料总结 - - -精品资料欢迎下载 - - - - - - - - - - - - - - - - - - 名师精心整理 - - - - - - - 第 2 页,共 13 页 - - - - - - - - - The dwMicroSecPerFrame field specifies the period between video frames. This value indicates the overall timing for the file. The dwMaxBytesPerSec field 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. The dwFlags field contains any flags for the file. The following flags are defined: AVIF_HASINDEX Indicates the AVI file has an idx1 chunk. AVIF_MUSTUSEINDEX Indicates the index should be used to determine the order of presentation of the data. AVIF_ISINTERLEAVED Indicates the AVI file is interleaved. AVIF_WASCAPTUREFILE Indicates the AVI file is a specially allocated file used for capturing real-time video. AVIF_COPYRIGHTED Indicates the AVI file contains copyrighted data. The AVIF_HASINDEX and AVIF_MUSTUSEINDEX flags applies to files with an index chunk. The AVI_HASINDEX flag indicates an index is present. The AVIF_MUSTUSEINDEX flag indicates the index should be used to determine the order of the presentation of the data. When this flag is set, it implies the physical ordering of the chunks in the file does not correspond to the presentation order. The AVIF_ISINTERLEAVED flag indicates the AVI file has been interleaved. The system can stream interleaved data from a CD-ROM more efficiently than non-interleaved data. For more information on interleaved files, see Special Information for Interleaved Files. The AVIF_WASCAPTUREFILE flag indicates the AVI file is a specially allocated file used for capturing real-time video. Typically, capture files have been defragmented by user so video capture data can be efficiently streamed into the file. If this flag is set, an application should warn the user before writing over the file with this flag. The AVIF_COPYRIGHTED flag indicates the AVI file contains copyrighted data. When this flag is set, applications should not let users duplicate the file or the data in the file. The dwTotalFrames field of the main header specifies the total number of frames of data in file. The dwInitialFrames is used for interleaved files. 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 field. The dwStreams field specifies the number of streams in the file. For example, a file with audio and video has 2 streams. The dwSuggestedBufferSize field 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. The dwWidth and dwHeight fields specify the width and height of the AVI file in pixels. The dwScale and dwRate fields are used to specify the general time scale that the file will use. In addition to this time scale, each stream can have its own time scale. The time scale in samples per second is determined by dividing dwRate by dwScale. The dwStart and dwLength fields specify the starting time of the AVI file and the length of the file. The units are defined by dwRate and dwScale. The dwStart field is usually set to zero. The Stream Header (strl) Chunks 名师资料总结 - - -精品资料欢迎下载 - - - - - - - - - - - - - - - - - - 名师精心整理 - - - - - - - 第 3 页,共 13 页 - - - - - - - - - The main header is followed by one or more strl chunks. (A strl chunk is required for each data stream.) These chunks contain information about the streams in the file. Each strl chunk must contain a stream header and stream format chunk. Stream header chunks are identified by the four-character code strh and stream format chunks are identified with the four-character code strf. In addition to the stream header and stream format chunks, the strl chunk might also contain a stream data chunk. Stream data chunks are identified with the four-character code strd. The stream header has the following data structure defined for it: typedef struct FOURCC fccType; FOURCC fccHandler; DWORD dwFlags; DWORD dwReserved1; DWORD dwInitialFrames; DWORD dwScale; DWORD dwRate; DWORD dwStart; DWORD dwLength; DWORD dwSuggestedBufferSize; DWORD dwQuality; DWORD dwSampleSize; AVIStreamHeader; The stream header specifies the type of data the stream contains, such as audio or video, by means of a four-character code. The fccType field is set to vids if the stream it specifies contains video data. It is set to auds if it contains audio data. The fccHandler field contains a four-character code describing the installable compressor or decompressor used with the data. The dwFlags field contains any flags for the data stream. The AVISF_DISABLED flag indicates that the stream data should be rendered only when explicitly enabled by the user. The AVISF_VIDEO_PALCHANGES flag indicates palette changes are embedded in the file. The dwInitialFrames is used for interleaved files. 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 field. The remaining fields describe the playback characteristics of the stream. These factors include the playback rate (dwScale and dwRate ), the starting time of the sequence (dwStart ), the length of the sequence (dwLength ), the size of the playback buffer (dwSuggestedBuffer ), an indicator of the data quality (dwQuality ), and sample size (dwSampleSize ). See the reference section for more information on these fields. Some of the fields in the stream header structure are also present in the main header structure. The data in the main header structure applies to the whole file while the data in the stream header structure applies only to a stream. A stream format (strf) chunk must follow a stream header (strh) chunk. The stream format chunk describes the format of the data in the stream. For video streams, the information in this chunk is a BITMAPINFO structure (including palette information if appropriate). For audio streams, the information in this chunk is a WAVEFORMATEX or PCMWAVEFORMAT structure. (The WAVEFORMATEX structure is an extended version of the WAVEFORMAT structure.) For more information on this structure, see the New Multimedia Data Types and Data Techniques Standards Update. The strl chunk might also contain a stream data (strd) chunk. If used, this chunk follows the stream format chunk. The format and content of this chunk is defined by installable compression or decompression drivers. Typically, drivers use this information for configuration. Applications that read and write RIFF files do not need to decode this information. They transfer this data to and from a driver as a memory block. An AVI player associates the stream headers in the LIST hdrl chunk with the stream data in the LIST movi chunk by using the order of the strl chunks. The first strl chunk appli名师资料总结 - - -精品资料欢迎下载 - - - - - - - - - - - - - - - - - - 名师精心整理 - - - - - - - 第 4 页,共 13 页 - - - - - - - - - es to stream 0, the second applies to stream 1, and so forth. For example, if the first strl chunk describes the wave audio data, the wave audio data is contained in stream 0. Similarly, if the second strl chunk describes video data, then the video data is contained in stream 1. The LIST movi Chunk Following the header information is a LIST movi chunk that contains chunks of the actual data in the streams; that is, the pictures and sounds themselves. The data chunks can reside directly in the LIST movi chunk or they might be grouped into rec chunks. The rec grouping implies that the grouped chunks should be read from disk all at once. This is used only for files specifically interleaved to play from CD-ROM. Like any RIFF chunk, the data chunks contain a four-character code to identify the chunk type. The four-character code that identifies each chunk consists of the stream number and a two-character code that defines the type of information encapsulated in the chunk. For example, a waveform chunk is identified by a two-character code of wb. If a waveform chunk corresponded to the second LIST hdrl stream description, it would have a four-character code of 01wb. Since all the format information is in the header, the audio data contained in these data chunks does not contain any information about its format. An audio data chunk has the following format (the # in the format represents the stream identifier): WAVE Bytes #wb BYTE abBytes; Video data can be compressed or uncompressed DIBs. An uncompressed DIB has BI_RGB specified for the biCompression field in its associated BITMAPINFO structure. A compressed DIB has a value other than BI_RGB specified in the biCompression field. For more information about compression formats, see the description of the BITMAPINFOHEADER data structure in the Microsoft Windows Programmers Reference and Chapter 5, DIB Format Extensions for Microsoft Windows. A data chunk for an uncompressed DIB contains RGB video data. These chunks are identified with a two-character code of db (db is an abbreviation for DIB bits). Data chunks for a compressed DIB are identified with a two-character code of dc (dc is an abbreviation for DIB compressed). Neither data chunk will contain any header information about the DIBs. The data chunk for an uncompressed DIB has the following form: DIB Bits #db BYTE abBits; The data chunk for a compressed DIB has the following form: Compressed DIB #dc BYTE abBits; Video data chunks can also define new palette entries used to update the palette during an AVI sequence. These chunks are identified with a two-character code of pc (pc is an abbreviation for palette change). The following data structure is defined palette information: typedef struct BYTE bFirstEntry; BYTE bNumEntries; WORD wFlags; PALETTEENTRY peNew; AVIPALCHANGE; The bFirstEntry field defines the first entry to change and the bNumEntries field specifies the number of entries to change. The peNew field contains the new color entries. If you include palette changes in a video stream, set the AVITF_VIDEO_PALCHANGES flag in the dwFlags field of the stream header. This flag indicates that this video stream contains palette changes and warns the playback software that it will need to animate the palette. The idx1 Chunk AVI files can have an index chunk after the LIST movi chunk. The index chunk essentially名师资料总结 - - -精品资料欢迎下载 - - - - - - - - - - - - - - - - - - 名师精心整理 - - - - - - - 第 5 页,共 13 页 - - - - - - - - - contains a list of the data chunks and their location in the file. This provides efficient random access to the data within the file, because an application can locate a particular sound sequence or video image in a large AVI file without having to scan it. Index chunks use the four-character code idx1. The following data structure is defined for index entries:

    注意事项

    本文(2022年avi格式 .pdf)为本站会员(Che****ry)主动上传,淘文阁 - 分享文档赚钱的网站仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知淘文阁 - 分享文档赚钱的网站(点击联系客服),我们立即给予删除!

    温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




    关于淘文阁 - 版权申诉 - 用户使用规则 - 积分规则 - 联系我们

    本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

    工信部备案号:黑ICP备15003705号 © 2020-2023 www.taowenge.com 淘文阁 

    收起
    展开