Skip to content

Commit bdaaab2

Browse files
author
Clement Champetier
committed
Profile: add getFormatProfiles
Get existing format profiles.
1 parent efd9d77 commit bdaaab2

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

src/AvTranscoder/Profile.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,19 @@ const Profile::ProfilesDesc& Profile::getProfiles()
114114
return _profiles;
115115
}
116116

117+
Profile::ProfilesDesc Profile::getFormatProfiles()
118+
{
119+
ProfilesDesc profiles;
120+
121+
for( ProfilesDesc::iterator it = _profiles.begin(); it != _profiles.end(); ++it )
122+
{
123+
if( (*it).find( avProfileType )->second == avProfileTypeFormat )
124+
profiles.push_back( *it );
125+
}
126+
127+
return profiles;
128+
}
129+
117130
Profile::ProfilesDesc Profile::getVideoProfiles()
118131
{
119132
ProfilesDesc profiles;

src/AvTranscoder/Profile.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ class Profile
4242

4343
const ProfilesDesc& getProfiles();
4444

45+
ProfilesDesc getFormatProfiles();
4546
ProfilesDesc getVideoProfiles();
4647
ProfilesDesc getAudioProfiles();
4748

0 commit comments

Comments
 (0)