File tree Expand file tree Collapse file tree 3 files changed +1
-12
lines changed Expand file tree Collapse file tree 3 files changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -266,7 +266,7 @@ void OutputFile::setupWrapping(const ProfileLoader::Profile& profile)
266
266
}
267
267
268
268
// check if output format indicated is valid with the filename extension
269
- if (!matchFormat (profile.find (constants::avProfileFormat)->second , getFilename ()))
269
+ if (!av_guess_format (profile.find (constants::avProfileFormat)->second . c_str () , getFilename (). c_str (), NULL ))
270
270
{
271
271
throw std::runtime_error (" Invalid format according to the file extension." );
272
272
}
Original file line number Diff line number Diff line change @@ -12,12 +12,6 @@ extern "C" {
12
12
namespace avtranscoder
13
13
{
14
14
15
- bool matchFormat (const std::string& format, const std::string& filename)
16
- {
17
- AVOutputFormat* avOutputFormat = av_guess_format (format.c_str (), filename.c_str (), NULL );
18
- return avOutputFormat != NULL ;
19
- }
20
-
21
15
std::vector<std::string> getSupportedPixelFormats (const std::string& videoCodecName)
22
16
{
23
17
std::vector<std::string> pixelFormats;
Original file line number Diff line number Diff line change @@ -19,11 +19,6 @@ namespace avtranscoder
19
19
typedef std::map<std::string, OptionArray> OptionArrayMap;
20
20
typedef std::map<std::string, std::string> NamesArray; // < short/long names of format/video codec/audio codec
21
21
22
- /* *
23
- * @brief Check if a format name corresponds to the format of a given filename
24
- */
25
- bool AvExport matchFormat (const std::string& format, const std::string& filename);
26
-
27
22
/* *
28
23
* @brief Get pixel format supported by a video codec.
29
24
* @param videoCodecName: the video codec name (empty if not indicated, and so get all pixel formats supported by all video
You can’t perform that action at this time.
0 commit comments