• 大小: 8.27MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-10-08
  • 语言: 其他
  • 标签: flv  

资源简介

H264_AAC_FLV_MUX_本地文件_1

资源截图

代码片段和文件信息

#include “AudioTag.h“

unsigned int decode_audio_done = 0;

int Detach_Head_Aac(ADTS_HEADER * adtsheader)
{
unsigned char Adts_Headr_Buf[ADTS_HEADER_LENGTH];
unsigned int readsize = 0;
readsize = ReadFile(pAudio_Aac_File Adts_Headr_BufADTS_HEADER_LENGTH);
if (readsize < 0)
{
printf(“ReadFile : pAudio_Aac_File ERROR\n“);
return getchar();
}
if (readsize == 0)
{
return readsize;
}
if ((Adts_Headr_Buf[0] == 0xFF)&&((Adts_Headr_Buf[1] & 0xF0) == 0xF0))    //syncword 12个1
{
adtsheader->syncword = (Adts_Headr_Buf[0] << 4 )  | (Adts_Headr_Buf[1]  >> 4);
adtsheader->id = ((unsigned int) Adts_Headr_Buf[1] & 0x08) >> 3;
adtsheader->layer = ((unsigned int) Adts_Headr_Buf[1] & 0x06) >> 1;
adtsheader->protection_absent = (unsigned int) Adts_Headr_Buf[1] & 0x01;
adtsheader->profile = ((unsigned int) Adts_Headr_Buf[2] & 0xc0) >> 6;
adtsheader->sf_index = ((unsigned int) Adts_Headr_Buf[2] & 0x3c) >> 2;
adtsheader->private_bit = ((unsigned int) Adts_Headr_Buf[2] & 0x02) >> 1;
adtsheader->channel_configuration = ((((unsigned int) Adts_Headr_Buf[2] & 0x01) << 2) | (((unsigned int) Adts_Headr_Buf[3] & 0xc0) >> 6));
adtsheader->original = ((unsigned int) Adts_Headr_Buf[3] & 0x20) >> 5;
adtsheader->home = ((unsigned int) Adts_Headr_Buf[3] & 0x10) >> 4;
adtsheader->copyright_identification_bit = ((unsigned int) Adts_Headr_Buf[3] & 0x08) >> 3;
adtsheader->copyright_identification_start = (unsigned int) Adts_Headr_Buf[3] & 0x04 >> 2;
adtsheader->aac_frame_length = (((((unsigned int) Adts_Headr_Buf[3]) & 0x03) << 11) | (((unsigned int) Adts_Headr_Buf[4] & 0xFF) << 3)| ((unsigned int) Adts_Headr_Buf[5] & 0xE0) >> 5) ;
adtsheader->adts_buffer_fullness = (((unsigned int) Adts_Headr_Buf[5] & 0x1f) << 6 | ((unsigned int) Adts_Headr_Buf[6] & 0xfc) >> 2);
adtsheader->no_raw_data_blocks_in_frame = ((unsigned int) Adts_Headr_Buf[6] & 0x03);
}
else 
{
printf(“ADTS_HEADER : BUF ERROR\n“);
getchar();
}
return readsize;
}

void Create_AudioSpecificConfig(unsigned char * buf
   unsigned char profile/*表示使用哪个级别的AAC,如01 Low Complexity(LC)--- AACLC*/
   unsigned char SoundRate/*采样率*/
   unsigned char SoundType/*声道*/ )
{
Audio_ASC audioasc;
audioasc.audioobjectType = profile;               
audioasc.samplingFrequencyIndex = SoundRate;
audioasc.channelConfiguration = SoundType;
audioasc.framelengthFlag = 0x00;
audioasc.dependsOnCoreCoder = 0x00;
audioasc.extensionFlag = 0x00;
buf[0] = (audioasc.audioobjectType << 3)  | (audioasc.samplingFrequencyIndex >> 1);
buf[1] = (((audioasc.samplingFrequencyIndex) & 0x01) <<  7) | 
(audioasc.channelConfiguration << 3)  | 
(audioasc.framelengthFlag << 2) | 
(audioasc.dependsOnCoreCoder << 1)  | 
(audioasc.extensionFlag);
}

int WriteStruct_Aac_Tag(unsigned char * Bufunsigned int  Timestampunsigned char AACPacketType/*AAC序列头部*/)
{
Audio_Tag audiotag;
unsigned int readsize = 0;
unsigne

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件     587692  2013-05-31 09:51  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\AAC_STREAM\22.aac

     文件     254717  2013-06-05 11:18  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\AAC_STREAM\33.aac

     文件      58880  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.exe

     文件     363860  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.ilk

     文件     478208  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.pdb

     文件       5375  2013-06-05 09:50  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\AudioTag.cpp

     文件       4779  2013-06-04 16:00  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\AudioTag.h

     文件      12574  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\AudioTag.obj

     文件      17350  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\BuildLog.htm

     文件       9356  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\FileIo.obj

     文件       6363  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\Flv.obj

     文件        663  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.exe.embed.manifest

     文件        728  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.exe.embed.manifest.res

     文件        621  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\H264_AAC_Flv_Mux.exe.intermediate.manifest

     文件       9574  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\Main.obj

     文件         67  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\mt.dep

     文件      21803  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\Mux.obj

     文件       8820  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\Mybs.obj

     文件       4291  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\Mycrc_32.obj

     文件      17367  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\scriptTag.obj

     文件     109568  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\vc90.idb

     文件      69632  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\vc90.pdb

     文件      25079  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Debug\VideoTag.obj

     文件        813  2013-05-27 09:52  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\FileIo.cpp

     文件        664  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\FileIo.h

     文件        987  2013-06-05 11:29  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Flv.cpp

     文件        965  2013-05-31 10:29  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Flv.h

     文件       4995  2013-06-03 11:10  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux.vcproj

     文件       1411  2013-06-05 11:43  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux.vcproj.chjj-PC.chjj.user

     文件        142  2013-05-14 15:04  H264_AAC_FLV_MUX_本地文件_1\H264_AAC_Flv_Mux\H264_AAC_Flv_Mux\Information.h

............此处省略27个文件信息

评论

共有 条评论