summaryrefslogtreecommitdiff
path: root/examples/make_dcp.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-01-06 08:28:18 +0000
committerCarl Hetherington <cth@carlh.net>2016-01-10 13:09:45 +0000
commit93f29880839dc5589bb35f63260a7152ead7655f (patch)
tree865dd65298dd11d949efed2ac3f58f3564c7cc8f /examples/make_dcp.cc
parentd7965cce4c5f95da7971bce6f800739a4cd2f17d (diff)
Introduce dc::Package, changing lots of namespaces in the process.
Diffstat (limited to 'examples/make_dcp.cc')
-rw-r--r--examples/make_dcp.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/examples/make_dcp.cc b/examples/make_dcp.cc
index b5402a96..99969dba 100644
--- a/examples/make_dcp.cc
+++ b/examples/make_dcp.cc
@@ -54,13 +54,13 @@ main ()
per second.
*/
- boost::shared_ptr<dcp::dc::MonoPictureAsset> picture_asset (new dcp::dc::MonoPictureAsset (dcp::dc::Fraction (24, 1)));
+ boost::shared_ptr<dcp::MonoPictureAsset> picture_asset (new dcp::MonoPictureAsset (dcp::Fraction (24, 1)));
/* Start off a write to it */
- boost::shared_ptr<dcp::dc::PictureAssetWriter> picture_writer = picture_asset->start_write ("DCP/picture.mxf", dcp::dc::SMPTE, false);
+ boost::shared_ptr<dcp::PictureAssetWriter> picture_writer = picture_asset->start_write ("DCP/picture.mxf", dcp::DCP_SMPTE, false);
/* Write 24 frames of the same JPEG2000 file */
- dcp::dc::File picture ("examples/help.j2c");
+ dcp::File picture ("examples/help.j2c");
for (int i = 0; i < 24; ++i) {
picture_writer->write (picture.data(), picture.size());
}
@@ -71,8 +71,8 @@ main ()
/* Now create a sound MXF. As before, create an object and a writer.
When creating the object we specify the sampling rate (48kHz) and the number of channels (2).
*/
- boost::shared_ptr<dcp::dc::SoundAsset> sound_asset (new dcp::dc::SoundAsset (dcp::dc::Fraction (24, 1), 48000, 2));
- boost::shared_ptr<dcp::dc::SoundAssetWriter> sound_writer = sound_asset->start_write ("DCP/sound.mxf", dcp::dc::SMPTE);
+ boost::shared_ptr<dcp::SoundAsset> sound_asset (new dcp::SoundAsset (dcp::Fraction (24, 1), 48000, 2));
+ boost::shared_ptr<dcp::SoundAssetWriter> sound_writer = sound_asset->start_write ("DCP/sound.mxf", dcp::DCP_SMPTE);
/* Write some sine waves */
float* audio[2];
@@ -99,13 +99,13 @@ main ()
reel->add (boost::shared_ptr<dcp::dc::ReelSoundAsset> (new dcp::dc::ReelSoundAsset (sound_asset, 0)));
/* Make a CPL with this reel */
- boost::shared_ptr<dcp::dc::CPL> cpl (new dcp::dc::CPL ("My film", dcp::dc::FEATURE));
+ boost::shared_ptr<dcp::dc::CPL> cpl (new dcp::dc::CPL ("My film", dcp::FEATURE));
cpl->add (reel);
/* Write the DCP */
dcp::dc::Package dcp ("DCP");
dcp.add (cpl);
- dcp.write_xml (dcp::dc::SMPTE);
+ dcp.write_xml (dcp::DCP_SMPTE);
return 0;
}