libdcp
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
dcp::MonoPictureFrame Class Reference

A single frame of a 2D (monoscopic) picture asset. More...

#include <mono_picture_frame.h>

Inheritance diagram for dcp::MonoPictureFrame:
dcp::Data

Public Member Functions

 MonoPictureFrame (boost::filesystem::path path)
 
 MonoPictureFrame (uint8_t const *data, int size)
 
 MonoPictureFrame (MonoPictureFrame const &)=delete
 
MonoPictureFrameoperator= (MonoPictureFrame const &)=delete
 
std::shared_ptr< OpenJPEGImagexyz_image (int reduce=0) const
 
uint8_t const * data () const override
 
uint8_t * data () override
 
int size () const override
 
- Public Member Functions inherited from dcp::Data
void write (boost::filesystem::path file) const
 
void write_via_temp (boost::filesystem::path temp, boost::filesystem::path final) const
 

Private Member Functions

 MonoPictureFrame (ASDCP::JP2K::MXFReader *reader, int n, std::shared_ptr< DecryptionContext >, bool check_hmac)
 

Private Attributes

std::shared_ptr< ASDCP::JP2K::FrameBuffer > _buffer
 

Friends

class AssetReader< ASDCP::JP2K::MXFReader, MonoPictureFrame >
 

Detailed Description

A single frame of a 2D (monoscopic) picture asset.

Definition at line 71 of file mono_picture_frame.h.

Constructor & Destructor Documentation

◆ MonoPictureFrame() [1/2]

MonoPictureFrame::MonoPictureFrame ( boost::filesystem::path  path)
explicit

Make a picture frame from a JPEG2000 file.

Parameters
pathPath to JPEG2000 file.

Definition at line 59 of file mono_picture_frame.cc.

◆ MonoPictureFrame() [2/2]

MonoPictureFrame::MonoPictureFrame ( ASDCP::JP2K::MXFReader *  reader,
int  n,
std::shared_ptr< DecryptionContext c,
bool  check_hmac 
)
private

Make a picture frame from a 2D (monoscopic) asset.

Parameters
readerReader for the asset's MXF file.
nFrame within the asset, not taking EntryPoint into account.
cContext for decryption, or 0.
check_hmactrue to check the HMAC and give an error if it is not as expected.

Definition at line 85 of file mono_picture_frame.cc.

Member Function Documentation

◆ data() [1/2]

uint8_t const * MonoPictureFrame::data ( ) const
overridevirtual
Returns
Pointer to JPEG2000 data

Implements dcp::Data.

Definition at line 107 of file mono_picture_frame.cc.

◆ data() [2/2]

uint8_t * MonoPictureFrame::data ( )
overridevirtual
Returns
Pointer to JPEG2000 data

Implements dcp::Data.

Definition at line 114 of file mono_picture_frame.cc.

◆ size()

int MonoPictureFrame::size ( ) const
overridevirtual
Returns
Size of JPEG2000 data in bytes

Implements dcp::Data.

Definition at line 121 of file mono_picture_frame.cc.

◆ xyz_image()

shared_ptr< OpenJPEGImage > MonoPictureFrame::xyz_image ( int  reduce = 0) const
Parameters
reducea factor by which to reduce the resolution of the image, expressed as a power of two (pass 0 for no reduction).

Definition at line 128 of file mono_picture_frame.cc.


The documentation for this class was generated from the following files: