Cleaned up TODOs from MPEG-2 code.
This commit is contained in:
parent
67bdd89ba2
commit
77e9302aa9
|
@ -25,8 +25,6 @@ class H264BitReader {
|
|||
// Initialize the reader to start reading at |data|, |size| being size
|
||||
// of |data| in bytes.
|
||||
// Return false on insufficient size of stream..
|
||||
// TODO(posciak,fischman): consider replacing Initialize() with
|
||||
// heap-allocating and creating bit readers on demand instead.
|
||||
bool Initialize(const uint8* data, off_t size);
|
||||
|
||||
// Read |num_bits| next bits from stream and return in |*out|, first bit
|
||||
|
|
|
@ -111,7 +111,6 @@ struct H264PPS {
|
|||
bool entropy_coding_mode_flag;
|
||||
bool bottom_field_pic_order_in_frame_present_flag;
|
||||
int num_slice_groups_minus1;
|
||||
// TODO(posciak): Slice groups not implemented, could be added at some point.
|
||||
int num_ref_idx_l0_default_active_minus1;
|
||||
int num_ref_idx_l1_default_active_minus1;
|
||||
bool weighted_pred_flag;
|
||||
|
@ -187,7 +186,7 @@ struct H264SliceHeader {
|
|||
int first_mb_in_slice;
|
||||
int slice_type;
|
||||
int pic_parameter_set_id;
|
||||
int colour_plane_id; // TODO(posciak): use this! http://crbug.com/139878
|
||||
int colour_plane_id;
|
||||
int frame_num;
|
||||
bool field_pic_flag;
|
||||
bool bottom_field_flag;
|
||||
|
@ -307,7 +306,6 @@ class H264Parser {
|
|||
// of the parsed structure in |*pps_id|/|*sps_id|.
|
||||
// To get a pointer to a given SPS/PPS structure, use GetSPS()/GetPPS(),
|
||||
// passing the returned |*sps_id|/|*pps_id| as parameter.
|
||||
// TODO(posciak,fischman): consider replacing returning Result from Parse*()
|
||||
// methods with a scoped_ptr and adding an AtEOS() function to check for EOS
|
||||
// if Parse*() return NULL.
|
||||
Result ParseSPS(int* sps_id);
|
||||
|
|
|
@ -223,8 +223,6 @@ bool EsParserH264::ParseInternal() {
|
|||
if (h264_parser_->ParseSliceHeader(nalu, &shdr) != H264Parser::kOk) {
|
||||
// Only accept an invalid SPS/PPS at the beginning when the stream
|
||||
// does not necessarily start with an SPS/PPS/IDR.
|
||||
// TODO(damienv): Should be able to differentiate a missing SPS/PPS
|
||||
// from a slice header parsing error.
|
||||
if (last_video_decoder_config_)
|
||||
return false;
|
||||
} else {
|
||||
|
@ -330,7 +328,7 @@ bool EsParserH264::UpdateVideoDecoderConfig(const H264SPS* sps) {
|
|||
return false;
|
||||
}
|
||||
|
||||
// TODO(damienv): a MAP unit can be either 16 or 32 pixels.
|
||||
// TODO: a MAP unit can be either 16 or 32 pixels.
|
||||
// although it's 16 pixels for progressive non MBAFF frames.
|
||||
uint16 width = (sps->pic_width_in_mbs_minus1 + 1) * 16;
|
||||
uint16 height = (sps->pic_height_in_map_units_minus1 + 1) * 16;
|
||||
|
|
|
@ -282,7 +282,6 @@ void Mp2tMediaParser::RegisterPmt(int program_number, int pmt_pid) {
|
|||
void Mp2tMediaParser::RegisterPes(int pmt_pid,
|
||||
int pes_pid,
|
||||
int stream_type) {
|
||||
// TODO(damienv): check there is no mismatch if the entry already exists.
|
||||
DVLOG(1) << "RegisterPes:"
|
||||
<< " pes_pid=" << pes_pid
|
||||
<< " stream_type=" << std::hex << stream_type << std::dec;
|
||||
|
|
|
@ -19,8 +19,6 @@ int TsPacket::Sync(const uint8* buf, int size) {
|
|||
for (; k < size; k++) {
|
||||
// Verify that we have 4 syncwords in a row when possible,
|
||||
// this should improve synchronization robustness.
|
||||
// TODO(damienv): Consider the case where there is garbage
|
||||
// between TS packets.
|
||||
bool is_header = true;
|
||||
for (int i = 0; i < 4; i++) {
|
||||
int idx = k + i * kPacketSize;
|
||||
|
@ -212,4 +210,3 @@ bool TsPacket::ParseAdaptationField(BitReader* bit_reader,
|
|||
|
||||
} // namespace mp2t
|
||||
} // namespace media
|
||||
|
||||
|
|
|
@ -286,7 +286,6 @@ bool TsSectionPes::ParseInternal(const uint8* raw_pes, int raw_pes_size) {
|
|||
}
|
||||
|
||||
// Discard the rest of the PES packet header.
|
||||
// TODO(damienv): check if some info of the PES packet header are useful.
|
||||
DCHECK_EQ(bit_reader.bits_available() % 8, 0);
|
||||
int pes_header_remaining_size = pes_header_data_length -
|
||||
(pes_header_start_size - bit_reader.bits_available() / 8);
|
||||
|
|
|
@ -57,10 +57,6 @@ bool TsSectionPmt::ParsePsiSection(BitReader* bit_reader) {
|
|||
RCHECK(section_number == 0);
|
||||
RCHECK(last_section_number == 0);
|
||||
|
||||
// TODO(damienv):
|
||||
// Verify that there is no mismatch between the program number
|
||||
// and the program number that was provided in a PAT for the current PMT.
|
||||
|
||||
// Read the end of the fixed length section.
|
||||
int pcr_pid;
|
||||
int program_info_length;
|
||||
|
@ -71,7 +67,6 @@ bool TsSectionPmt::ParsePsiSection(BitReader* bit_reader) {
|
|||
RCHECK(program_info_length < 1024);
|
||||
|
||||
// Read the program info descriptor.
|
||||
// TODO(damienv): check wether any of the descriptors could be useful.
|
||||
// Defined in section 2.6 of ISO-13818.
|
||||
RCHECK(bit_reader->SkipBits(8 * program_info_length));
|
||||
|
||||
|
@ -97,7 +92,6 @@ bool TsSectionPmt::ParsePsiSection(BitReader* bit_reader) {
|
|||
pid_map.insert(std::pair<int, int>(pid_es, stream_type));
|
||||
|
||||
// Read the ES info descriptors.
|
||||
// TODO(damienv): check wether any of the descriptors could be useful.
|
||||
// Defined in section 2.6 of ISO-13818.
|
||||
RCHECK(bit_reader->SkipBits(8 * es_info_length));
|
||||
}
|
||||
|
@ -119,4 +113,3 @@ void TsSectionPmt::ResetPsiSection() {
|
|||
|
||||
} // namespace mp2t
|
||||
} // namespace media
|
||||
|
||||
|
|
|
@ -17,7 +17,6 @@ class TsSectionPmt : public TsSectionPsi {
|
|||
// RegisterPesCb::Run(int pes_pid, int stream_type);
|
||||
// Stream type is defined in
|
||||
// "Table 2-34 – Stream type assignments" in H.222
|
||||
// TODO(damienv): add the program number.
|
||||
typedef base::Callback<void(int, int)> RegisterPesCb;
|
||||
|
||||
explicit TsSectionPmt(const RegisterPesCb& register_pes_cb);
|
||||
|
|
Loading…
Reference in New Issue