13
0

Check for OGG format properly. Should fix #3723.

git-svn-id: svn://localhost/ardour2/branches/3.0@8559 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2011-01-21 00:58:36 +00:00
parent 184d5167db
commit 34d8df6a37
2 changed files with 4 additions and 2 deletions

View File

@ -84,7 +84,8 @@ SndFileImportableSource::natural_position () const
bool
SndFileImportableSource::clamped_at_unity () const
{
int const type = sf_info.format & SF_FORMAT_TYPEMASK;
int const sub = sf_info.format & SF_FORMAT_SUBMASK;
/* XXX: this may not be the full list of formats that are unclamped */
return (sub != SF_FORMAT_FLOAT && sub != SF_FORMAT_DOUBLE && sub != SF_FORMAT_OGG);
return (sub != SF_FORMAT_FLOAT && sub != SF_FORMAT_DOUBLE && type != SF_FORMAT_OGG);
}

View File

@ -877,9 +877,10 @@ SndFileSource::one_of_several_channels () const
bool
SndFileSource::clamped_at_unity () const
{
int const type = _info.format & SF_FORMAT_TYPEMASK;
int const sub = _info.format & SF_FORMAT_SUBMASK;
/* XXX: this may not be the full list of formats that are unclamped */
return (sub != SF_FORMAT_FLOAT && sub != SF_FORMAT_DOUBLE);
return (sub != SF_FORMAT_FLOAT && sub != SF_FORMAT_DOUBLE && type != SF_FORMAT_OGG);
}
void