Skip to content

Commit 4407685

Browse files
committed
(Reader,Writer,Effect)Base.cpp: std:: prefixes
1 parent 182db74 commit 4407685

File tree

3 files changed

+84
-84
lines changed

3 files changed

+84
-84
lines changed

src/EffectBase.cpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,15 @@ void EffectBase::InitEffectInfo()
5050

5151
// Display file information
5252
void EffectBase::DisplayInfo() {
53-
cout << fixed << setprecision(2) << boolalpha;
54-
cout << "----------------------------" << endl;
55-
cout << "----- Effect Information -----" << endl;
56-
cout << "----------------------------" << endl;
57-
cout << "--> Name: " << info.name << endl;
58-
cout << "--> Description: " << info.description << endl;
59-
cout << "--> Has Video: " << info.has_video << endl;
60-
cout << "--> Has Audio: " << info.has_audio << endl;
61-
cout << "----------------------------" << endl;
53+
std::cout << std::fixed << std::setprecision(2) << std::boolalpha;
54+
std::cout << "----------------------------" << std::endl;
55+
std::cout << "----- Effect Information -----" << std::endl;
56+
std::cout << "----------------------------" << std::endl;
57+
std::cout << "--> Name: " << info.name << std::endl;
58+
std::cout << "--> Description: " << info.description << std::endl;
59+
std::cout << "--> Has Video: " << info.has_video << std::endl;
60+
std::cout << "--> Has Audio: " << info.has_audio << std::endl;
61+
std::cout << "----------------------------" << std::endl;
6262
}
6363

6464
// Constrain a color value from 0 to 255

src/ReaderBase.cpp

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -68,49 +68,49 @@ ReaderBase::ReaderBase()
6868

6969
// Display file information
7070
void ReaderBase::DisplayInfo() {
71-
cout << fixed << setprecision(2) << boolalpha;
72-
cout << "----------------------------" << endl;
73-
cout << "----- File Information -----" << endl;
74-
cout << "----------------------------" << endl;
75-
cout << "--> Has Video: " << info.has_video << endl;
76-
cout << "--> Has Audio: " << info.has_audio << endl;
77-
cout << "--> Has Single Image: " << info.has_single_image << endl;
78-
cout << "--> Duration: " << info.duration << " Seconds" << endl;
79-
cout << "--> File Size: " << double(info.file_size) / 1024 / 1024 << " MB" << endl;
80-
cout << "----------------------------" << endl;
81-
cout << "----- Video Attributes -----" << endl;
82-
cout << "----------------------------" << endl;
83-
cout << "--> Width: " << info.width << endl;
84-
cout << "--> Height: " << info.height << endl;
85-
cout << "--> Pixel Format: " << info.pixel_format << endl;
86-
cout << "--> Frames Per Second: " << info.fps.ToDouble() << " (" << info.fps.num << "/" << info.fps.den << ")" << endl;
87-
cout << "--> Video Bit Rate: " << info.video_bit_rate/1000 << " kb/s" << endl;
88-
cout << "--> Pixel Ratio: " << info.pixel_ratio.ToDouble() << " (" << info.pixel_ratio.num << "/" << info.pixel_ratio.den << ")" << endl;
89-
cout << "--> Display Aspect Ratio: " << info.display_ratio.ToDouble() << " (" << info.display_ratio.num << "/" << info.display_ratio.den << ")" << endl;
90-
cout << "--> Video Codec: " << info.vcodec << endl;
91-
cout << "--> Video Length: " << info.video_length << " Frames" << endl;
92-
cout << "--> Video Stream Index: " << info.video_stream_index << endl;
93-
cout << "--> Video Timebase: " << info.video_timebase.ToDouble() << " (" << info.video_timebase.num << "/" << info.video_timebase.den << ")" << endl;
94-
cout << "--> Interlaced: " << info.interlaced_frame << endl;
95-
cout << "--> Interlaced: Top Field First: " << info.top_field_first << endl;
96-
cout << "----------------------------" << endl;
97-
cout << "----- Audio Attributes -----" << endl;
98-
cout << "----------------------------" << endl;
99-
cout << "--> Audio Codec: " << info.acodec << endl;
100-
cout << "--> Audio Bit Rate: " << info.audio_bit_rate/1000 << " kb/s" << endl;
101-
cout << "--> Sample Rate: " << info.sample_rate << " Hz" << endl;
102-
cout << "--> # of Channels: " << info.channels << endl;
103-
cout << "--> Channel Layout: " << info.channel_layout << endl;
104-
cout << "--> Audio Stream Index: " << info.audio_stream_index << endl;
105-
cout << "--> Audio Timebase: " << info.audio_timebase.ToDouble() << " (" << info.audio_timebase.num << "/" << info.audio_timebase.den << ")" << endl;
106-
cout << "----------------------------" << endl;
107-
cout << "--------- Metadata ---------" << endl;
108-
cout << "----------------------------" << endl;
71+
std::cout << std::fixed << std::setprecision(2) << std::boolalpha;
72+
std::cout << "----------------------------" << std::endl;
73+
std::cout << "----- File Information -----" << std::endl;
74+
std::cout << "----------------------------" << std::endl;
75+
std::cout << "--> Has Video: " << info.has_video << std::endl;
76+
std::cout << "--> Has Audio: " << info.has_audio << std::endl;
77+
std::cout << "--> Has Single Image: " << info.has_single_image << std::endl;
78+
std::cout << "--> Duration: " << info.duration << " Seconds" << std::endl;
79+
std::cout << "--> File Size: " << double(info.file_size) / 1024 / 1024 << " MB" << std::endl;
80+
std::cout << "----------------------------" << std::endl;
81+
std::cout << "----- Video Attributes -----" << std::endl;
82+
std::cout << "----------------------------" << std::endl;
83+
std::cout << "--> Width: " << info.width << std::endl;
84+
std::cout << "--> Height: " << info.height << std::endl;
85+
std::cout << "--> Pixel Format: " << info.pixel_format << std::endl;
86+
std::cout << "--> Frames Per Second: " << info.fps.ToDouble() << " (" << info.fps.num << "/" << info.fps.den << ")" << std::endl;
87+
std::cout << "--> Video Bit Rate: " << info.video_bit_rate/1000 << " kb/s" << std::endl;
88+
std::cout << "--> Pixel Ratio: " << info.pixel_ratio.ToDouble() << " (" << info.pixel_ratio.num << "/" << info.pixel_ratio.den << ")" << std::endl;
89+
std::cout << "--> Display Aspect Ratio: " << info.display_ratio.ToDouble() << " (" << info.display_ratio.num << "/" << info.display_ratio.den << ")" << std::endl;
90+
std::cout << "--> Video Codec: " << info.vcodec << std::endl;
91+
std::cout << "--> Video Length: " << info.video_length << " Frames" << std::endl;
92+
std::cout << "--> Video Stream Index: " << info.video_stream_index << std::endl;
93+
std::cout << "--> Video Timebase: " << info.video_timebase.ToDouble() << " (" << info.video_timebase.num << "/" << info.video_timebase.den << ")" << std::endl;
94+
std::cout << "--> Interlaced: " << info.interlaced_frame << std::endl;
95+
std::cout << "--> Interlaced: Top Field First: " << info.top_field_first << std::endl;
96+
std::cout << "----------------------------" << std::endl;
97+
std::cout << "----- Audio Attributes -----" << std::endl;
98+
std::cout << "----------------------------" << std::endl;
99+
std::cout << "--> Audio Codec: " << info.acodec << std::endl;
100+
std::cout << "--> Audio Bit Rate: " << info.audio_bit_rate/1000 << " kb/s" << std::endl;
101+
std::cout << "--> Sample Rate: " << info.sample_rate << " Hz" << std::endl;
102+
std::cout << "--> # of Channels: " << info.channels << std::endl;
103+
std::cout << "--> Channel Layout: " << info.channel_layout << std::endl;
104+
std::cout << "--> Audio Stream Index: " << info.audio_stream_index << std::endl;
105+
std::cout << "--> Audio Timebase: " << info.audio_timebase.ToDouble() << " (" << info.audio_timebase.num << "/" << info.audio_timebase.den << ")" << std::endl;
106+
std::cout << "----------------------------" << std::endl;
107+
std::cout << "--------- Metadata ---------" << std::endl;
108+
std::cout << "----------------------------" << std::endl;
109109

110110
// Iterate through metadata
111111
std::map<std::string, std::string>::iterator it;
112112
for (it = info.metadata.begin(); it != info.metadata.end(); it++)
113-
cout << "--> " << it->first << ": " << it->second << endl;
113+
std::cout << "--> " << it->first << ": " << it->second << std::endl;
114114
}
115115

116116
// Generate Json::JsonValue for this object

src/WriterBase.cpp

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -100,42 +100,42 @@ void WriterBase::CopyReaderInfo(ReaderBase* reader)
100100

101101
// Display file information
102102
void WriterBase::DisplayInfo() {
103-
cout << fixed << setprecision(2) << boolalpha;
104-
cout << "----------------------------" << endl;
105-
cout << "----- File Information -----" << endl;
106-
cout << "----------------------------" << endl;
107-
cout << "--> Has Video: " << info.has_video << endl;
108-
cout << "--> Has Audio: " << info.has_audio << endl;
109-
cout << "--> Has Single Image: " << info.has_single_image << endl;
110-
cout << "--> Duration: " << info.duration << " Seconds" << endl;
111-
cout << "--> File Size: " << double(info.file_size) / 1024 / 1024 << " MB" << endl;
112-
cout << "----------------------------" << endl;
113-
cout << "----- Video Attributes -----" << endl;
114-
cout << "----------------------------" << endl;
115-
cout << "--> Width: " << info.width << endl;
116-
cout << "--> Height: " << info.height << endl;
117-
cout << "--> Pixel Format: " << info.pixel_format << endl;
118-
cout << "--> Frames Per Second: " << info.fps.ToDouble() << " (" << info.fps.num << "/" << info.fps.den << ")" << endl;
119-
cout << "--> Video Bit Rate: " << info.video_bit_rate/1000 << " kb/s" << endl;
120-
cout << "--> Pixel Ratio: " << info.pixel_ratio.ToDouble() << " (" << info.pixel_ratio.num << "/" << info.pixel_ratio.den << ")" << endl;
121-
cout << "--> Display Aspect Ratio: " << info.display_ratio.ToDouble() << " (" << info.display_ratio.num << "/" << info.display_ratio.den << ")" << endl;
122-
cout << "--> Video Codec: " << info.vcodec << endl;
123-
cout << "--> Video Length: " << info.video_length << " Frames" << endl;
124-
cout << "--> Video Stream Index: " << info.video_stream_index << endl;
125-
cout << "--> Video Timebase: " << info.video_timebase.ToDouble() << " (" << info.video_timebase.num << "/" << info.video_timebase.den << ")" << endl;
126-
cout << "--> Interlaced: " << info.interlaced_frame << endl;
127-
cout << "--> Interlaced: Top Field First: " << info.top_field_first << endl;
128-
cout << "----------------------------" << endl;
129-
cout << "----- Audio Attributes -----" << endl;
130-
cout << "----------------------------" << endl;
131-
cout << "--> Audio Codec: " << info.acodec << endl;
132-
cout << "--> Audio Bit Rate: " << info.audio_bit_rate/1000 << " kb/s" << endl;
133-
cout << "--> Sample Rate: " << info.sample_rate << " Hz" << endl;
134-
cout << "--> # of Channels: " << info.channels << endl;
135-
cout << "--> Channel Layout: " << info.channel_layout << endl;
136-
cout << "--> Audio Stream Index: " << info.audio_stream_index << endl;
137-
cout << "--> Audio Timebase: " << info.audio_timebase.ToDouble() << " (" << info.audio_timebase.num << "/" << info.audio_timebase.den << ")" << endl;
138-
cout << "----------------------------" << endl;
103+
std::cout << std::fixed << std::setprecision(2) << std::boolalpha;
104+
std::cout << "----------------------------" << std::endl;
105+
std::cout << "----- File Information -----" << std::endl;
106+
std::cout << "----------------------------" << std::endl;
107+
std::cout << "--> Has Video: " << info.has_video << std::endl;
108+
std::cout << "--> Has Audio: " << info.has_audio << std::endl;
109+
std::cout << "--> Has Single Image: " << info.has_single_image << std::endl;
110+
std::cout << "--> Duration: " << info.duration << " Seconds" << std::endl;
111+
std::cout << "--> File Size: " << double(info.file_size) / 1024 / 1024 << " MB" << std::endl;
112+
std::cout << "----------------------------" << std::endl;
113+
std::cout << "----- Video Attributes -----" << std::endl;
114+
std::cout << "----------------------------" << std::endl;
115+
std::cout << "--> Width: " << info.width << std::endl;
116+
std::cout << "--> Height: " << info.height << std::endl;
117+
std::cout << "--> Pixel Format: " << info.pixel_format << std::endl;
118+
std::cout << "--> Frames Per Second: " << info.fps.ToDouble() << " (" << info.fps.num << "/" << info.fps.den << ")" << std::endl;
119+
std::cout << "--> Video Bit Rate: " << info.video_bit_rate/1000 << " kb/s" << std::endl;
120+
std::cout << "--> Pixel Ratio: " << info.pixel_ratio.ToDouble() << " (" << info.pixel_ratio.num << "/" << info.pixel_ratio.den << ")" << std::endl;
121+
std::cout << "--> Display Aspect Ratio: " << info.display_ratio.ToDouble() << " (" << info.display_ratio.num << "/" << info.display_ratio.den << ")" << std::endl;
122+
std::cout << "--> Video Codec: " << info.vcodec << std::endl;
123+
std::cout << "--> Video Length: " << info.video_length << " Frames" << std::endl;
124+
std::cout << "--> Video Stream Index: " << info.video_stream_index << std::endl;
125+
std::cout << "--> Video Timebase: " << info.video_timebase.ToDouble() << " (" << info.video_timebase.num << "/" << info.video_timebase.den << ")" << std::endl;
126+
std::cout << "--> Interlaced: " << info.interlaced_frame << std::endl;
127+
std::cout << "--> Interlaced: Top Field First: " << info.top_field_first << std::endl;
128+
std::cout << "----------------------------" << std::endl;
129+
std::cout << "----- Audio Attributes -----" << std::endl;
130+
std::cout << "----------------------------" << std::endl;
131+
std::cout << "--> Audio Codec: " << info.acodec << std::endl;
132+
std::cout << "--> Audio Bit Rate: " << info.audio_bit_rate/1000 << " kb/s" << std::endl;
133+
std::cout << "--> Sample Rate: " << info.sample_rate << " Hz" << std::endl;
134+
std::cout << "--> # of Channels: " << info.channels << std::endl;
135+
std::cout << "--> Channel Layout: " << info.channel_layout << std::endl;
136+
std::cout << "--> Audio Stream Index: " << info.audio_stream_index << std::endl;
137+
std::cout << "--> Audio Timebase: " << info.audio_timebase.ToDouble() << " (" << info.audio_timebase.num << "/" << info.audio_timebase.den << ")" << std::endl;
138+
std::cout << "----------------------------" << std::endl;
139139
}
140140

141141
// Generate JSON string of this object

0 commit comments

Comments
 (0)