Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(594)

Unified Diff: media/filters/h264_to_annex_b_bitstream_converter.cc

Issue 10690140: Reorganize bitstream converter classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/filters/h264_to_annex_b_bitstream_converter.cc
diff --git a/media/base/h264_bitstream_converter.cc b/media/filters/h264_to_annex_b_bitstream_converter.cc
similarity index 95%
rename from media/base/h264_bitstream_converter.cc
rename to media/filters/h264_to_annex_b_bitstream_converter.cc
index 4e154f218d4f4fc17e29c8d09a41e39f904c70fb..78a40ac790dee68dc62bf86121c0e56145e42275 100644
--- a/media/base/h264_bitstream_converter.cc
+++ b/media/filters/h264_to_annex_b_bitstream_converter.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "media/base/h264_bitstream_converter.h"
+#include "media/filters/h264_to_annex_b_bitstream_converter.h"
#include "base/logging.h"
@@ -25,15 +25,15 @@ static bool IsAccessUnitBoundaryNal(int nal_unit_type) {
return false;
}
-H264BitstreamConverter::H264BitstreamConverter()
+H264ToAnnexBBitstreamConverter::H264ToAnnexBBitstreamConverter()
: configuration_processed_(false),
first_nal_unit_in_access_unit_(true),
nal_unit_length_field_width_(0) {
}
-H264BitstreamConverter::~H264BitstreamConverter() {}
+H264ToAnnexBBitstreamConverter::~H264ToAnnexBBitstreamConverter() {}
-uint32 H264BitstreamConverter::ParseConfigurationAndCalculateSize(
+uint32 H264ToAnnexBBitstreamConverter::ParseConfigurationAndCalculateSize(
const uint8* configuration_record,
uint32 configuration_record_size) {
// FFmpeg's AVCodecContext's extradata field contains the Decoder Specific
@@ -94,7 +94,7 @@ uint32 H264BitstreamConverter::ParseConfigurationAndCalculateSize(
return parameter_set_size_bytes;
}
-uint32 H264BitstreamConverter::CalculateNeededOutputBufferSize(
+uint32 H264ToAnnexBBitstreamConverter::CalculateNeededOutputBufferSize(
const uint8* input,
uint32 input_size) const {
uint32 output_size = 0;
@@ -147,7 +147,8 @@ uint32 H264BitstreamConverter::CalculateNeededOutputBufferSize(
return output_size;
}
-bool H264BitstreamConverter::ConvertAVCDecoderConfigurationRecordToByteStream(
+bool H264ToAnnexBBitstreamConverter::
+ ConvertAVCDecoderConfigurationRecordToByteStream(
Ami GONE FROM CHROMIUM 2012/07/11 22:33:17 style-guide is silent on how this should be indent
xhwang 2012/07/12 00:21:45 Done.
const uint8* input,
uint32 input_size,
uint8* output,
@@ -226,7 +227,7 @@ bool H264BitstreamConverter::ConvertAVCDecoderConfigurationRecordToByteStream(
return true;
}
-bool H264BitstreamConverter::ConvertNalUnitStreamToByteStream(
+bool H264ToAnnexBBitstreamConverter::ConvertNalUnitStreamToByteStream(
const uint8* input, uint32 input_size,
uint8* output, uint32* output_size) {
const uint8* inscan = input; // We read the input from here progressively

Powered by Google App Engine
This is Rietveld 408576698