mehdi141
11th April 2007, 06:34
Dear All,
I want to generate Mp4 file with multiple sps and pps.
I saw some reference code of Mp4 "Bento4", where in 'avcC' atoms has the entries of SPS (sequence parameter set) and PPS (picture parameter set).
In which avcC box contain
1 number of SPS 8-bit
2 length of SPS 16-bit
3 data of SPS how much data of sps
4 number of PPS 8-bit
5 length of PPS 16-bit
6 data of PPS how much data of pps
when i am muxing mp4 file then sending same way multiple sps and pps then QuickTime is not playing only Blank While screen come for video but auido is runing properly..
But when i demux with yamb (muxer) then same h.264 generated with multiple sps and pps ..
i have 2 Question in my mind.
1: may be i am missing some field of another atom of mp4 which is dependent on this avcC Box
2: may be QuickTime does not support multiple SPS in Mp4 file.
This is my request of all of u, if u have any type of soultion are guidline then please reply me..
Thanks
some reference code
Code ::
uint8 num_seq_params = quenceParameters.ItemCount()&0x31);
stream.WriteUI08(0xE0 | num_seq_params);
for (unsigned int i=0; i<num_seq_params; i++)
{
AP4_UI16 param_length = m_SequenceParameters[i].GetDataSize();
stream.WriteUI16(param_length);
stream.Write(m_SequenceParameters[i].GetData(), param_length);
}
AP4_UI08 num_pic_params= PictureParameters.ItemCount();
stream.WriteUI08(num_pic_params);
for (unsigned int i=0; i<num_pic_params; i++)
{
AP4_UI16 param_length =m_PictureParameters[i].GetDataSize();
stream.WriteUI16(param_length);
stream.Write(m_PictureParameters[i].GetData(), param_length);
}
Mehdi Husain
I want to generate Mp4 file with multiple sps and pps.
I saw some reference code of Mp4 "Bento4", where in 'avcC' atoms has the entries of SPS (sequence parameter set) and PPS (picture parameter set).
In which avcC box contain
1 number of SPS 8-bit
2 length of SPS 16-bit
3 data of SPS how much data of sps
4 number of PPS 8-bit
5 length of PPS 16-bit
6 data of PPS how much data of pps
when i am muxing mp4 file then sending same way multiple sps and pps then QuickTime is not playing only Blank While screen come for video but auido is runing properly..
But when i demux with yamb (muxer) then same h.264 generated with multiple sps and pps ..
i have 2 Question in my mind.
1: may be i am missing some field of another atom of mp4 which is dependent on this avcC Box
2: may be QuickTime does not support multiple SPS in Mp4 file.
This is my request of all of u, if u have any type of soultion are guidline then please reply me..
Thanks
some reference code
Code ::
uint8 num_seq_params = quenceParameters.ItemCount()&0x31);
stream.WriteUI08(0xE0 | num_seq_params);
for (unsigned int i=0; i<num_seq_params; i++)
{
AP4_UI16 param_length = m_SequenceParameters[i].GetDataSize();
stream.WriteUI16(param_length);
stream.Write(m_SequenceParameters[i].GetData(), param_length);
}
AP4_UI08 num_pic_params= PictureParameters.ItemCount();
stream.WriteUI08(num_pic_params);
for (unsigned int i=0; i<num_pic_params; i++)
{
AP4_UI16 param_length =m_PictureParameters[i].GetDataSize();
stream.WriteUI16(param_length);
stream.Write(m_PictureParameters[i].GetData(), param_length);
}
Mehdi Husain