Remove the bools and default parameters from SoundAsset::start_write().
[libdcp.git] / src / sound_asset.cc
index 8002f37a0fedc66ca620ef62117b67934eb487bd..56d13951ee5781d5b878459bc59347df0ce41d2c 100644 (file)
@@ -221,13 +221,19 @@ SoundAsset::equals (shared_ptr<const Asset> other, EqualityOptions opt, NoteHand
 
 
 shared_ptr<SoundAssetWriter>
-SoundAsset::start_write(boost::filesystem::path file, bool atmos_sync, bool include_mca_subdescriptors)
+SoundAsset::start_write(
+       boost::filesystem::path file,
+       AtmosSync atmos_sync,
+       MCASubDescriptors include_mca_subdescriptors
+       )
 {
-       if (atmos_sync && _channels < 14) {
+       if (atmos_sync == AtmosSync::ENABLED && _channels < 14) {
                throw MiscError ("Insufficient channels to write ATMOS sync (there must be at least 14)");
        }
 
-       return shared_ptr<SoundAssetWriter>(new SoundAssetWriter(this, file, atmos_sync, include_mca_subdescriptors));
+       return shared_ptr<SoundAssetWriter>(
+               new SoundAssetWriter(this, file, atmos_sync == AtmosSync::ENABLED, include_mca_subdescriptors == MCASubDescriptors::ENABLED)
+               );
 }