diff options
| author | Carl Hetherington <cth@carlh.net> | 2021-01-13 02:16:37 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2021-01-17 20:13:23 +0100 |
| commit | 33942a6c7ab40dfe1ccb87e80497fc0b5390b76a (patch) | |
| tree | 8e77c3aa3927fe9d186d921ed8a0a8e0dd96d974 /test/test.cc | |
| parent | 5c57052dfeda55dc218001b089ebcdaaf6bedc3b (diff) | |
Bv2.1 7.3: audio sample rate must be 48kHz.
Diffstat (limited to 'test/test.cc')
| -rw-r--r-- | test/test.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/test.cc b/test/test.cc index 88fdb3a9..f110c9cb 100644 --- a/test/test.cc +++ b/test/test.cc @@ -276,9 +276,8 @@ simple_picture (boost::filesystem::path path, string suffix, int frames) shared_ptr<dcp::SoundAsset> -simple_sound (boost::filesystem::path path, string suffix, dcp::MXFMetadata mxf_meta, string language, int frames) +simple_sound (boost::filesystem::path path, string suffix, dcp::MXFMetadata mxf_meta, string language, int frames, int sample_rate) { - int const sample_rate = 48000; int const channels = 1; /* Set a valid language, then overwrite it, so that the language parameter can be badly formed */ @@ -289,7 +288,7 @@ simple_sound (boost::filesystem::path path, string suffix, dcp::MXFMetadata mxf_ active_channels.push_back (dcp::LEFT); shared_ptr<dcp::SoundAssetWriter> sound_writer = ms->start_write (path / dcp::String::compose("audio%1.mxf", suffix), active_channels); - int const samples_per_frame = 48000 / 24; + int const samples_per_frame = sample_rate / 24; float* silence[channels]; for (auto i = 0; i < channels; ++i) { |
