Skip to content

Commit c90265e

Browse files
author
Clement Champetier
committed
Transcoder: remove _outputFps attribute
* The method setOutputFps does not do what the user expected: the fps of Transcoder is only used for progress bar (no consequencies in transcode process !). * This kind of method must be implemented in the outputStream on which we want to update the fps.
1 parent 221e11b commit c90265e

File tree

3 files changed

+1
-11
lines changed

3 files changed

+1
-11
lines changed

app/genericProcessor/genericProcessor.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,6 @@ int main( int argc, char** argv )
116116
// set verbose of all stream
117117
transcoder.setVerbose( verbose );
118118
transcoder.setProcessMethod( avtranscoder::eProcessMethodLongest );
119-
//transcoder.setOutputFps( 12 );
120119
transcoder.init();
121120

122121
if( verbose )

src/AvTranscoder/transcoder/Transcoder.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ Transcoder::Transcoder( OutputFile& outputFile )
1212
, _inputFiles()
1313
, _streamTranscoders()
1414
, _profile( true )
15-
, _outputFps( 25 )
1615
, _eProcessMethod ( eProcessMethodLongest )
1716
, _mainStreamIndex( 0 )
1817
, _verbose( false )
@@ -266,7 +265,7 @@ void Transcoder::process( IProgress& progress )
266265
if( ! processFrame() )
267266
break;
268267

269-
if( progress.progress( 1 / _outputFps * ( frame ), totalDuration ) == eJobStatusCancel )
268+
if( progress.progress( 1 / 25. * ( frame ), totalDuration ) == eJobStatusCancel )
270269
{
271270
break;
272271
}

src/AvTranscoder/transcoder/Transcoder.hpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,6 @@ class AvExport Transcoder
133133
*/
134134
void setVerbose( bool verbose = true );
135135

136-
/**
137-
* @brief Set FPS of output media file.
138-
* @note By default 25 frames per second.
139-
*/
140-
void setOutputFps( double fps ) { _outputFps = fps; }
141-
142136
private:
143137

144138
void addRewrapStream( const std::string& filename, const size_t streamIndex );
@@ -176,8 +170,6 @@ class AvExport Transcoder
176170

177171
Profile _profile; ///< Objet to get existing profiles, and add new ones for the Transcoder.
178172

179-
double _outputFps;
180-
181173
EProcessMethod _eProcessMethod;
182174

183175
size_t _mainStreamIndex; ///< Index of stream used to stop the process of transcode in case of eProcessMethodBasedOnStream.

0 commit comments

Comments
 (0)