本文整理汇总了C++中Skip_SB函数的典型用法代码示例。如果您正苦于以下问题:C++ Skip_SB函数的具体用法?C++ Skip_SB怎么用?C++ Skip_SB使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了Skip_SB函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Skip_C4
//---------------------------------------------------------------------------
void File_Als::FileHeader_Parse()
{
//Parsing
int32u SampleRate, Samples;
int16u Channels;
int8u BitsPerSample, FileType;
Skip_C4( "signature");
Get_B4 (SampleRate, "sample rate");
Get_B4 (Samples, "samples");
Get_B2 (Channels, "channels-1"); Param_Info2(Channels+1, " channel(s)");
BS_Begin();
Get_S1 (3, FileType, "file type"); // WAV, RIFF, AIFF
Get_S1 (3, BitsPerSample, "bits per sample"); Param_Info2((BitsPerSample+1)*8, " bits");
Skip_SB( "floating point");
Skip_SB( "samples are big-endian");
BS_End();
FILLING_BEGIN();
if (!CalcDurationUncompressedSize(Samples, SampleRate, (BitsPerSample+1)*8, Channels))
return;
File__Tags_Helper::Accept("ALS");
File__Tags_Helper::Stream_Prepare(Stream_Audio);
Fill(Stream_Audio, 0, Audio_Format, "ALS");
Fill(Stream_Audio, 0, Audio_Codec, "ALS");
Fill(Stream_Audio, 0, Audio_BitDepth, (BitsPerSample+1)*8);
Fill(Stream_Audio, StreamPos_Last, Audio_Channel_s_, Channels+1);
Fill(Stream_Audio, StreamPos_Last, Audio_SamplingRate, SampleRate);
Fill(Stream_Audio, 0, Audio_Duration, Duration);
//No more need data
File__Tags_Helper::Finish("ALS");
FILLING_END();
}
示例2: Element_Begin1
//---------------------------------------------------------------------------
void File_Aac::DSTSpecificConfig()
{
Element_Begin1("DSTSpecificConfig");
Skip_SB("DSDDST_Coded");
Skip_S2(14,"N_Channels");
Skip_SB("reserved");
Element_End0();
}
示例3: Element_Name
//---------------------------------------------------------------------------
// Packet "B0"
void File_AvsV::video_sequence_start()
{
Element_Name("video_sequence_start");
//Parsing
int32u bit_rate_upper, bit_rate_lower;
Get_B1 ( profile_id, "profile_id");
Get_B1 ( level_id, "level_id");
BS_Begin();
Get_SB ( progressive_sequence, "progressive_sequence");
Get_S2 (14, horizontal_size, "horizontal_size");
Get_S2 (14, vertical_size, "vertical_size");
Get_S1 ( 2, chroma_format, "chroma_format");
Skip_S1( 3, "sample_precision");
Get_S1 ( 4, aspect_ratio, "aspect_ratio"); Param_Info(AvsV_aspect_ratio[aspect_ratio]);
Get_S1 ( 4, frame_rate_code, "frame_rate_code"); Param_Info(AvsV_frame_rate[frame_rate_code]);
Get_S3 (18, bit_rate_lower, "bit_rate_lower");
Mark_1 ();
Get_S3 (12, bit_rate_upper, "bit_rate_upper");
bit_rate=(bit_rate_upper<<18)+bit_rate_lower; Param_Info(bit_rate*8, " bps");
Get_SB ( low_delay, "low_delay");
Mark_1 ();
Skip_S3(18, "bbv_buffer_size");
Skip_SB( "reserved");
Skip_SB( "reserved");
Skip_SB( "reserved");
BS_End();
//Not sure, but the 3 first official files have this
if (Element_Size-Element_Offset)
{
BS_Begin();
Mark_1();
BS_End();
}
FILLING_BEGIN();
//NextCode
NextCode_Clear();
NextCode_Add(0xB2); //user_data_start
NextCode_Add(0xB3); //picture_start (I)
NextCode_Add(0xB5); //extension_start
//Autorisation of other streams
Streams[0xB1].Searching_Payload=true, //video_sequence_end
Streams[0xB2].Searching_Payload=true; //user_data_start
Streams[0xB3].Searching_Payload=true, //picture_start (I)
Streams[0xB4].Searching_Payload=true, //reserved
Streams[0xB5].Searching_Payload=true; //extension_start
Streams[0xB6].Searching_Payload=true, //picture_start (P or B)
Streams[0xB7].Searching_Payload=true; //video_edit
Streams[0xB8].Searching_Payload=true, //reserved
video_sequence_start_IsParsed=true;
FILLING_END();
}
示例4: Element_Begin1
//---------------------------------------------------------------------------
void File_Cdp::ccsvcinfo_section()
{
//Parsing
int8u svc_count;
Element_Begin1("ccsvcinfo_section");
Skip_B1( "ccsvcinfo_id");
BS_Begin();
Skip_SB( "reserved");
Skip_SB( "svc_info_start");
Skip_SB( "svc_info_change");
Skip_SB( "svc_info_complete");
Get_S1 (4, svc_count, "svc_count");
BS_End();
for (int8u Pos=0; Pos<svc_count; Pos++)
{
Element_Begin1("svc");
bool csn_size;
BS_Begin();
Skip_SB( "reserved");
Get_SB ( csn_size, "csn_size");
if (csn_size)
{
Skip_SB( "reserved");
Skip_S1(5, "caption_service_number");
}
else
Skip_S1(6, "caption_service_number");
BS_End();
//svc_data_byte - caption_service_descriptor
Element_Begin1("service");
Ztring language;
bool digital_cc;
Get_Local(3, language, "language");
BS_Begin();
Get_SB (digital_cc, "digital_cc");
Skip_SB( "reserved");
if (digital_cc) //line21
{
Skip_S1(5, "reserved");
Skip_SB( "line21_field");
}
else
Skip_S1(6, "caption_service_number");
Skip_SB( "easy_reader");
Skip_SB( "wide_aspect_ratio");
Skip_S2(14, "reserved");
BS_End();
Element_End0();
Element_End0();
}
Element_End0();
}
示例5: BS_Begin
//---------------------------------------------------------------------------
void File_Mpeg4_Descriptors::Descriptor_02()
{
//Parsing
bool URL_Flag;
BS_Begin();
Skip_S2(10, "ObjectDescriptorID");
Get_SB ( URL_Flag, "URL_Flag");
Skip_SB( "includeInlineProfileLevelFlag");
Skip_S1( 4, "reserved");
BS_End();
if (URL_Flag)
{
int8u URLlength;
Get_B1 (URLlength, "URLlength");
Skip_UTF8(URLlength, "URLstring");
}
Info_B1(ODProfileLevel, "ODProfileLevelIndication"); Param_Info(Mpeg4_Descriptors_ODProfileLevelIndication(ODProfileLevel));
Info_B1(SceneProfileLevel, "sceneProfileLevelIndication"); Param_Info(Mpeg4_Descriptors_SceneProfileLevelIndication(SceneProfileLevel));
Info_B1(AudioProfileLevel, "audioProfileLevelIndication"); Param_Info(Mpeg4_Descriptors_AudioProfileLevelIndication(AudioProfileLevel));
Info_B1(VisualProfileLevel, "visualProfileLevelIndication"); Param_Info(Mpeg4_Descriptors_VisualProfileLevelIndication(VisualProfileLevel));
Info_B1(GraphicsProfileLevel, "graphicsProfileLevelIndication"); Param_Info(Mpeg4_Descriptors_GraphicsProfileLevelIndication(GraphicsProfileLevel));
FILLING_BEGIN();
Element_ThisIsAList();
FILLING_END();
}
示例6: Get_B2
//---------------------------------------------------------------------------
void File_Pcm_M2ts::Read_Buffer_Continue()
{
if (Buffer_Size==0)
return;
//Parsing
int16u audio_data_payload_size;
Get_B2 ( audio_data_payload_size, "audio_data_payload_size");
BS_Begin();
Get_S1 (4, channel_assignment, "channel_assignment"); Param_Info2(Pcm_M2TS_channel_assignment[channel_assignment], " channel(s)");
Get_S1 (4, sampling_frequency, "sampling_frequency"); Param_Info2(Pcm_M2TS_sampling_frequency[sampling_frequency], " Hz");
Get_S1 (2, bits_per_sample, "bits_per_sample"); Param_Info2(Pcm_M2TS_bits_per_sample[bits_per_sample], " bits");
Skip_SB( "start_flag");
Skip_S1(5, "reserved");
BS_End();
Skip_XX(audio_data_payload_size, "audio_data_payload");
FILLING_BEGIN_PRECISE();
if (!Status[IsAccepted])
{
Accept();
Finish();
}
FILLING_END();
}
示例7: BS_Begin
//---------------------------------------------------------------------------
void File_Amr::Header_Parse()
{
BS_Begin();
Skip_SB( "Frame Following");
Get_S1 ( 4, FrameType, "Frame Type");
Skip_SB( "Frame Quality");
Skip_SB( "Unknown");
Skip_SB( "Unknown");
BS_End();
//Filling
if (Amr_BitRate[FrameType]==0)
{
Finish("AMR");
return;
}
Header_Fill_Size(Amr_BitRate[FrameType]/400);
Header_Fill_Code(0, "frame");
}
示例8: Element_Name
//---------------------------------------------------------------------------
// Packet "0E"
void File_Vc1::EntryPointHeader()
{
Element_Name("EntryPointHeader");
//Parsing
bool extended_mv;
BS_Begin();
Skip_SB( "broken_link");
Skip_SB( "closed_entry");
Get_SB ( panscan_flag, "panscan_flag");
Skip_SB( "refdist_flag");
Skip_SB( "loopfilter");
Skip_SB( "fastuvmc");
Get_SB ( extended_mv, "extended_mv");
Skip_S1( 2, "dquant");
Skip_SB( "vstransform");
Skip_SB( "overlap");
Skip_S1( 2, "quantizer");
if (hrd_param_flag)
for (int8u Pos=0; Pos<hrd_num_leaky_buckets; Pos++)
{
Element_Begin("leaky_bucket");
Skip_S2( 8, "hrd_full");
Element_End();
}
TEST_SB_SKIP( "coded_size_flag");
Info_S2(12, coded_width, "coded_width"); Param_Info((coded_width+1)*2, " pixels");
Info_S2(12, coded_height, "coded_height"); Param_Info((coded_height+1)*2, " pixels");
TEST_SB_END();
if (extended_mv)
Skip_SB( "extended_dmv");
TEST_SB_SKIP( "luma_sampling");
Skip_S1( 3, "y_range");
TEST_SB_END();
TEST_SB_SKIP( "chroma_sampling");
Skip_S1( 3, "uv_range");
TEST_SB_END();
BS_End();
FILLING_BEGIN();
//NextCode
NextCode_Test();
NextCode_Clear();
NextCode_Add(0x0D);
//Autorisation of other streams
Streams[0x0D].Searching_Payload=true;
EntryPoint_Parsed=true;
FILLING_END();
}
示例9: Element_Begin
//---------------------------------------------------------------------------
void File_Latm::StreamMuxConfig()
{
Element_Begin("StreamMuxConfig");
bool audioMuxVersion;
Get_SB (audioMuxVersion, "audioMuxVersion");
if (audioMuxVersion)
Get_SB (audioMuxVersionA, "audioMuxVersionA");
else
audioMuxVersionA=false;
if (!audioMuxVersionA)
{
if (audioMuxVersion==1)
{
//taraBufferFullness=LatmGetValue();
}
Skip_SB( "allStreamsSameTimeFraming");
Skip_S1(6, "numSubFrames");
Skip_S1(4, "numProgram");
/* for (int8u prog=0; prog<=numProgram; prog++)
{
int8u numLayer;
Get_S1(3, "numLayer");
for (lay = 0; lay <= numLayer; lay++) {
progSIndx[streamCnt] = prog; laySIndx[streamCnt] = lay;
streamID [ prog][ lay] = streamCnt++;
if (prog == 0 && lay == 0) {
useSameConfig = 0;
} else {
useSameConfig; 1 uimsbf
}
if (! useSameConfig) {
if ( audioMuxVersion == 0 ) {
AudioSpecificConfig();
}
else {
ascLen = LatmGetValue();
ascLen -= AudioSpecificConfig(); Note 1
fillBits; ascLen bslbf
}
}
*/
}
Element_End();
}
示例10: Skip_L1
//---------------------------------------------------------------------------
void File_Tak::STREAMINFO()
{
//Parsing
int32u num_samples_hi, samplerate;
int8u num_samples_lo, framesizecode, samplesize;
bool channels;
Skip_L1 ( "unknown");
BS_Begin();
Get_S1 ( 2, num_samples_lo, "num_samples (lo)");
Get_S1 ( 3, framesizecode, "framesizecode");
Skip_S1( 2, "unknown");
BS_End();
Get_L4 (num_samples_hi, "num_samples (hi)"); Param_Info2((((int64u)num_samples_hi)<<2 | num_samples_lo), " samples");
Get_L3 (samplerate, "samplerate"); Param_Info2((samplerate/16)+6000, " Hz");
BS_Begin();
Skip_S1( 4, "unknown");
Get_SB ( channels, "channels"); Param_Info1(channels?"Stereo":"Mono");
Get_S1 ( 2, samplesize, "samplesize"); Param_Info1(Tak_samplesize[samplesize]);
Skip_SB( "unknown");
BS_End();
Skip_L3( "crc");
FILLING_BEGIN()
//Coherency
if (samplerate==0)
return;
//Computing
int64u Samples=((int64u)num_samples_hi)<<2 | num_samples_lo;
int32u SamplingRate=(samplerate/16)+6000;
//Filling
File__Tags_Helper::Accept("TAK");
File__Tags_Helper::Stream_Prepare(Stream_Audio);
Fill(Stream_Audio, 0, Audio_Format, "TAK");
Fill(Stream_Audio, 0, Audio_Codec, "TAK");
Fill(Stream_Audio, 0, Audio_SamplingRate, SamplingRate);
Fill(Stream_Audio, 0, Audio_Channel_s_, channels?2:1);
if (Tak_samplesize[samplesize])
Fill(Stream_Audio, 0, Audio_BitDepth, Tak_samplesize[samplesize]);
Fill(Stream_Audio, 0, Audio_Duration, Samples*1000/SamplingRate);
FILLING_END();
}
示例11: Element_Begin
//---------------------------------------------------------------------------
void File_Mpc::FileHeader_Parse()
{
//Parsing
Element_Begin("SV7 header", 21);
Ztring Encoder;
int32u FrameCount;
int16u TitleGain, AlbumGain;
int8u Profile, Link, SampleFreq, EncoderVersion;
Skip_C3( "Signature");
BS_Begin();
Skip_S1(4, "PNS");
Skip_S1(4, "Version");
BS_End();
Get_L4 (FrameCount, "FrameCount");
Skip_L2( "MaxLevel");
BS_Begin();
Get_S1 (4, Profile, "Profile"); Param_Info(Mpc_Profile[Profile]);
Get_S1 (2, Link, "Link"); Param_Info(Mpc_Link[Link]);
Get_S1 (2, SampleFreq, "SampleFreq"); Param_Info(Mpc_SampleFreq[SampleFreq]);
Skip_SB( "IntensityStereo");
Skip_SB( "MidSideStereo");
Skip_S1(6, "MaxBand");
BS_End();
Skip_L2( "TitlePeak");
Get_L2 (TitleGain, "TitleGain"); Param_Info(((float32)((int16s)TitleGain))/1000, 2, " dB");
Skip_L2( "AlbumPeak");
Get_L2 (AlbumGain, "AlbumGain"); Param_Info(((float32)((int16s)TitleGain))/1000, 2, " dB");
BS_Begin();
Skip_S2(16, "unused");
Skip_S1( 4, "LastFrameLength (part 1)");
Skip_SB( "FastSeekingSafe");
Skip_S1( 3, "unused");
Skip_SB( "TrueGapless");
Skip_S1( 7, "LastFrameLength (part 2)");
BS_End();
Get_L1 (EncoderVersion, "EncoderVersion");
Encoder.From_Number(((float)EncoderVersion)/100, 2); if (EncoderVersion%10==0); else if (EncoderVersion%2==0) Encoder+=_T(" Beta"); else if (EncoderVersion%2==1) Encoder+=_T(" Alpha"); Param_Info(Encoder);
Element_End();
FILLING_BEGIN();
File__Tags_Helper::Accept("Musepack SV7");
File__Tags_Helper::Stream_Prepare(Stream_Audio);
Fill(Stream_Audio, 0, Audio_SamplingRate, Mpc_SampleFreq[SampleFreq]);
Fill(Stream_Audio, 0, Audio_SamplingCount, FrameCount*1152);
Fill(Stream_Audio, 0, Audio_Format, "Musepack SV7");
Fill(Stream_Audio, 0, Audio_Codec, "SV7");
Fill(Stream_Audio, 0, Audio_Codec_Settings, Mpc_Profile[Profile]);
Fill(Stream_Audio, 0, Audio_Encoded_Library, Encoder);
Fill(Stream_Audio, 0, Audio_Resolution, 16); //MPC support only 16 bits
Fill(Stream_Audio, 0, Audio_Duration, ((int64u)FrameCount)*1152*1000/Mpc_SampleFreq[SampleFreq]);
if (FrameCount)
Fill(Stream_Audio, 0, Audio_BitRate, (File_Size-25)*8*Mpc_SampleFreq[SampleFreq]/FrameCount/1152);
//No more need data
File__Tags_Helper::Finish("Musepack SV7");
FILLING_END();
}
示例12: Get_B1
//---------------------------------------------------------------------------
void File_Mpeg4_Descriptors::Descriptor_06()
{
//Parsing
int8u predefined, timeStampLength;
bool durationFlag, useTimeStampsFlag;
Get_B1 (predefined, "predefined"); Param_Info(Mpeg4_Descriptors_Predefined(predefined));
switch (predefined)
{
case 0x00 :
{
BS_Begin();
Skip_SB( "useAccessUnitStartFlag");
Skip_SB( "useAccessUnitEndFlag");
Skip_SB( "useRandomAccessPointFlag");
Skip_SB( "hasRandomAccessUnitsOnlyFlag");
Skip_SB( "usePaddingFlag");
Get_SB (useTimeStampsFlag, "useTimeStampsFlag");
Skip_SB( "useIdleFlag");
Get_SB (durationFlag, "durationFlag");
BS_End();
Skip_B4( "timeStampResolution");
Skip_B4( "OCRResolution");
Get_B1 (timeStampLength, "timeStampLength");
Skip_B1( "OCRLength");
Skip_B1( "AU_Length");
Skip_B1( "instantBitrateLength");
BS_Begin();
Skip_S1(4, "degradationPriorityLength");
Skip_S1(5, "AU_seqNumLength");
Skip_S1(5, "packetSeqNumLength");
Skip_S1(2, "reserved");
BS_End();
}
break;
case 0x01 :
useTimeStampsFlag=false;
durationFlag=false;
timeStampLength=32;
break;
case 0x02 :
useTimeStampsFlag=true;
durationFlag=false;
timeStampLength=32;
break;
default :
useTimeStampsFlag=false;
durationFlag=false;
timeStampLength=32;
}
if (durationFlag)
{
Skip_B4( "timeScale");
Skip_B2( "accessUnitDuration");
Skip_B2( "compositionUnitDuration");
}
if (!useTimeStampsFlag)
{
BS_Begin();
Skip_S8(timeStampLength, "startDecodingTimeStamp");
Skip_S8(timeStampLength, "startCompositionTimeStamp");
BS_End();
}
}
示例13: Skip_B2
//---------------------------------------------------------------------------
void File_Jpeg::SIZ()
{
//Parsing
vector<float> SamplingFactors;
vector<int8u> BitDepths;
int8u SamplingFactors_Max=0;
int32u Xsiz, Ysiz;
int16u Count;
Skip_B2( "Rsiz - Capability of the codestream");
Get_B4 (Xsiz, "Xsiz - Image size X");
Get_B4 (Ysiz, "Ysiz - Image size Y");
Skip_B4( "XOsiz - Image offset X");
Skip_B4( "YOsiz - Image offset Y");
Skip_B4( "tileW - Size of tile W");
Skip_B4( "tileH - Size of tile H");
Skip_B4( "XTOsiz - Upper-left tile offset X");
Skip_B4( "YTOsiz - Upper-left tile offset Y");
Get_B2 (Count, "Components and initialize related arrays");
for (int16u Pos=0; Pos<Count; Pos++)
{
Element_Begin1("Initialize related array");
int8u BitDepth = 0, compSubsX = 0, compSubsY = 0;
BS_Begin();
Skip_SB( "Signed");
Get_S1 (7, BitDepth, "BitDepth"); Param_Info1(1+BitDepth); Element_Info1(1+BitDepth);
BS_End();
Get_B1 ( compSubsX, "compSubsX"); Element_Info1(compSubsX);
Get_B1 ( compSubsY, "compSubsY"); Element_Info1(compSubsY);
Element_End0();
//Filling list of HiVi
if (compSubsX)
{
SamplingFactors.push_back(((float)compSubsY)/compSubsX);
if (((float)compSubsY)/compSubsX>SamplingFactors_Max)
SamplingFactors_Max=(int8u)((float)compSubsY)/compSubsX;
}
if (BitDepths.empty() || BitDepth!=BitDepths[0])
BitDepths.push_back(BitDepth);
}
FILLING_BEGIN_PRECISE();
if (Frame_Count==0 && Field_Count==0)
{
Accept("JPEG 2000");
if (Count_Get(StreamKind_Last)==0)
Stream_Prepare(StreamKind_Last);
Fill(StreamKind_Last, 0, Fill_Parameter(StreamKind_Last, Generic_Format), "JPEG 2000");
Fill(StreamKind_Last, 0, Fill_Parameter(StreamKind_Last, Generic_Codec), "JPEG 2000");
if (StreamKind_Last==Stream_Image)
Fill(Stream_Image, 0, Image_Codec_String, "JPEG 2000", Unlimited, true, true); //To Avoid automatic filling
Fill(StreamKind_Last, 0, StreamKind_Last==Stream_Image?(size_t)Image_Width:(size_t)Video_Width, Xsiz);
Fill(StreamKind_Last, 0, StreamKind_Last==Stream_Image?(size_t)Image_Height:(size_t)Video_Height, Ysiz*(Interlaced?2:1)); //If image is from interlaced content, must multiply height by 2
if (BitDepths.size()==1)
Fill(StreamKind_Last, 0, Fill_Parameter(StreamKind_Last, Generic_BitDepth), 1+BitDepths[0]);
//Chroma subsampling
if (SamplingFactors_Max)
while (SamplingFactors_Max<4)
{
for (size_t Pos=0; Pos<SamplingFactors.size(); Pos++)
SamplingFactors[Pos]*=2;
SamplingFactors_Max*=2;
}
while (SamplingFactors.size()<3)
SamplingFactors.push_back(0);
Ztring ChromaSubsampling;
for (size_t Pos=0; Pos<SamplingFactors.size(); Pos++)
ChromaSubsampling+=Ztring::ToZtring(SamplingFactors[Pos], 0)+__T(':');
if (!ChromaSubsampling.empty())
{
ChromaSubsampling.resize(ChromaSubsampling.size()-1);
Fill(StreamKind_Last, 0, "ChromaSubsampling", ChromaSubsampling);
}
}
FILLING_END();
}
示例14: Skip_B4
//---------------------------------------------------------------------------
void File_Dts::Header_Parse()
{
//Parsing
int16u Primary_Frame_Byte_Size_minus_1;
int8u EncoderSoftwareRevision;
bool crc_present;
Skip_B4( "Sync");
BS_Begin();
Info_SB( FrameType, "Frame Type"); Param_Info(DTS_FrameType[FrameType]);
Skip_S1( 5, "Deficit Sample Count");
Get_SB ( crc_present, "CRC Present");
Skip_S1( 7, "Number of PCM Sample Blocks");
Get_S2 (14, Primary_Frame_Byte_Size_minus_1, "Primary Frame Byte Size minus 1");
Primary_Frame_Byte_Size_minus_1+=1;
if (!Word) Primary_Frame_Byte_Size_minus_1=Primary_Frame_Byte_Size_minus_1*8/14*2; Param_Info(Ztring::ToZtring(Primary_Frame_Byte_Size_minus_1)+_T(" bytes")); //Word is on 14 bits!
Get_S1 ( 6, channel_arrangement, "Audio Channel Arrangement"); Param_Info(Ztring::ToZtring(DTS_Channels[channel_arrangement])+_T(" channels"));
Get_S1 ( 4, sample_frequency, "Core Audio Sampling Frequency"); Param_Info(Ztring::ToZtring(DTS_SamplingRate[sample_frequency])+_T(" Hz"));
Get_S1 ( 5, bit_rate, "Transmission Bit Rate"); Param_Info(Ztring::ToZtring(DTS_BitRate[bit_rate])+_T(" bps"));
Skip_SB( "Embedded Down Mix Enabled");
Skip_SB( "Embedded Dynamic Range");
Skip_SB( "Embedded Time Stamp");
Skip_SB( "Auxiliary Data");
Skip_SB( "HDCD");
Get_S1 ( 3, ExtensionAudioDescriptor, "Extension Audio Descriptor"); Param_Info(DTS_ExtensionAudioDescriptor[ExtensionAudioDescriptor]);
Get_SB ( ExtendedCoding, "Extended Coding");
Skip_SB( "Audio Sync Word Insertion");
Get_S1 ( 2, lfe_effects, "Low Frequency Effects");
Skip_SB( "Predictor History");
if (crc_present)
Skip_S2(16, "Header CRC Check");
Skip_SB( "Multirate Interpolator");
Get_S1 ( 4, EncoderSoftwareRevision, "Encoder Software Revision");
Skip_S1( 2, "Copy History");
Get_S1 ( 2, bits_per_sample, "Source PCM Resolution"); Param_Info(Ztring::ToZtring(DTS_Resolution[bits_per_sample])+_T(" bits"));
Skip_SB( "ES");
Skip_SB( "Front Sum/Difference");
Skip_SB( "Surrounds Sum/Difference");
Skip_S1( 4, "Dialog Normalisation Parameter");
switch (EncoderSoftwareRevision)
{
case 6 :
Skip_S1( 4, "Dialog Normalisation Parameter");
break;
case 7 :
Skip_S1( 4, "Dialog Normalisation Parameter");
break;
default :
Skip_S1( 4, "Unspecified");
break;
}
BS_End();
//Filling
Header_Fill_Size(Primary_Frame_Byte_Size_minus_1+DTS_HD_Unknown_Size); //TODO: change this, for DTS-HD
Header_Fill_Code(0, "Frame");
}
示例15: Skip_XX
//---------------------------------------------------------------------------
void File_Gxf_TimeCode::Read_Buffer_Continue()
{
int8u Validity[504];
if (!IsAtc)
{
if (Element_Size!=4096)
{
Skip_XX(Element_Size, "Data");
return;
}
//Reading bitmap first (validity of first byte is at the end)
Element_Offset=504*8;
Element_Begin1("Validity");
BS_Begin_LE(); //is Little Endian
for (size_t Pos=0; Pos<504; Pos++)
{
bool Validity_Bit;
Get_TB (Validity_Bit, "Bit");
Validity[Pos]=Validity_Bit?1:0;
}
BS_End_LE();
Skip_B1( "Pad");
Element_End0();
}
//Parsing
Element_Offset=0;
for (size_t Pos=0; Pos<(IsAtc?(size_t)1:(size_t)504); Pos++)
{
if (IsAtc || Validity[Pos])
{
Element_Begin1("TimeCode");
int8u Frames_Units, Frames_Tens, Seconds_Units, Seconds_Tens, Minutes_Units, Minutes_Tens, Hours_Units, Hours_Tens;
bool DropFrame;
int8u DBB1=0, DBB2=0;
if (IsAtc)
{
bool Temp;
BS_Begin();
Get_S1 (4, Frames_Units, "Frames (Units)");
Get_SB ( Temp, "DBB1_0"); if (Temp) DBB1|=(1<<0);
Skip_S1(3, "Zero");
Skip_S1(4, "BG1");
Get_SB ( Temp, "DBB1_1"); if (Temp) DBB1|=(1<<1);
Skip_S1(3, "Zero");
Skip_SB( "CF - Color fame");
Get_SB ( DropFrame, "DP - Drop frame");
Get_S1 (2, Frames_Tens, "Frames (Tens)");
Get_SB ( Temp, "DBB1_2"); if (Temp) DBB1|=(1<<2);
Skip_S1(3, "Zero");
Skip_S1(4, "BG2");
Get_SB ( Temp, "DBB1_3"); if (Temp) DBB1|=(1<<3);
Skip_S1(3, "Zero");
Get_S1 (4, Seconds_Units, "Seconds (Units)");
Get_SB ( Temp, "DBB1_4"); if (Temp) DBB1|=(1<<4);
Skip_S1(3, "Zero");
Skip_S1(4, "BG3");
Get_SB ( Temp, "DBB1_5"); if (Temp) DBB1|=(1<<5);
Skip_S1(3, "Zero");
Skip_SB( "FM - Frame Mark");
Get_S1 (3, Seconds_Tens, "Seconds (Tens)");
Get_SB ( Temp, "DBB1_6"); if (Temp) DBB1|=(1<<6);
Skip_S1(3, "Zero");
Skip_S1(4, "BG4");
Get_SB ( Temp, "DBB1_7"); if (Temp) DBB1|=(1<<7);
Skip_S1(3, "Zero");
Get_S1 (4, Minutes_Units, "Minutes (Units)");
Get_SB ( Temp, "DBB2_0"); if (Temp) DBB2|=(1<<0);
Skip_S1(3, "Zero");
Skip_S1(4, "BG5");
Get_SB ( Temp, "DBB2_1"); if (Temp) DBB2|=(1<<1);
Skip_S1(3, "Zero");
Skip_SB( "BGF0");
Get_S1 (3, Minutes_Tens, "Minutes (Tens)");
Get_SB ( Temp, "DBB2_2"); if (Temp) DBB2|=(1<<2);
Skip_S1(3, "Zero");
Skip_S1(4, "BG6");
Get_SB ( Temp, "DBB2_3"); if (Temp) DBB2|=(1<<3);
Skip_S1(3, "Zero");
Get_S1 (4, Hours_Units, "Hours (Units)");
Get_SB ( Temp, "DBB2_4"); if (Temp) DBB2|=(1<<4);
Skip_S1(3, "Zero");
Skip_S1(4, "BG7");
//.........这里部分代码省略.........