|
SilentEye 0.4.1
|
Generic representation of Media which can load and hide specific data according to it's format. More...
#include <media.h>
Public Types | |
| enum | Type { IMAGE, AUDIO, VIDEO, UNKNOW } |
Public Member Functions | |
| Media () | |
| ~Media () | |
| Media (const QString &filepath) | |
| Media (const Media &img) | |
| Media (Media *img) | |
| Type | type () const |
| QPointer< EncodedData > | encodedData () const |
| void | setEncodedData (QPointer< EncodedData > data) |
| QString | filePath () const |
| QString | baseName () const |
| QString | shortName () const |
| void | setShortName (const QString shortName) |
| bool | isDataLoaded () const |
| virtual quint32 | capacity () const |
| virtual bool | loadData () |
| virtual bool | saveToDir (QString &outputDirPath) |
Protected Member Functions | |
| QString | fileName (QString filePath) |
| void | computeNewFileName (QString extension) |
Protected Attributes | |
| Type | m_type |
| Media type (Image/Audio/Video) | |
| QPointer< EncodedData > | m_data |
| Embedded data. | |
| QString | m_filePath |
| Media file path. | |
| QString | m_shortName |
| Media name. | |
| bool | m_isLoaded |
| Indicate when Media contains some data. | |
Generic representation of Media which can load and hide specific data according to it's format.
| SilentEyeFramework::Media::Media | ( | ) |
Definition at line 20 of file media.cpp.
References m_filePath, m_isLoaded, m_shortName, m_type, SEFormatBMP::setObjectName(), and UNKNOW.
| SilentEyeFramework::Media::Media | ( | const QString & | filepath | ) |
Definition at line 29 of file media.cpp.
References fileName(), filePath(), m_filePath, m_isLoaded, m_shortName, m_type, SEFormatBMP::setObjectName(), and UNKNOW.
| SilentEyeFramework::Media::Media | ( | const Media & | img | ) |
Definition at line 38 of file media.cpp.
References encodedData(), filePath(), m_data, m_filePath, m_isLoaded, m_shortName, m_type, SEFormatBMP::setObjectName(), shortName(), and UNKNOW.
| SilentEyeFramework::Media::Media | ( | Media * | img | ) |
Definition at line 48 of file media.cpp.
References filePath(), m_filePath, m_isLoaded, m_shortName, m_type, SEFormatBMP::setObjectName(), shortName(), and UNKNOW.
| QString SilentEyeFramework::Media::baseName | ( | ) | const |
Definition at line 114 of file media.cpp.
References m_filePath.
Referenced by computeNewFileName().
| quint32 SilentEyeFramework::Media::capacity | ( | ) | const [virtual] |
Reimplemented in SEFormatBMP::ImageBMP, SEFormatJPEG::ImageJPEG, SEFormatJPEG::ImageJPEG, and SEFormatWAV::AudioWav.
Definition at line 98 of file media.cpp.
Referenced by SilentEye::PropertyDialog::setMedia().
| void SilentEyeFramework::Media::computeNewFileName | ( | QString | extension | ) | [protected] |
Definition at line 124 of file media.cpp.
References baseName(), m_filePath, and m_shortName.
| QPointer< EncodedData > SilentEyeFramework::Media::encodedData | ( | ) | const |
| QString SilentEyeFramework::Media::fileName | ( | QString | filePath | ) | [protected] |
| QString SilentEyeFramework::Media::filePath | ( | ) | const |
Definition at line 88 of file media.cpp.
References m_filePath.
Referenced by Media(), SilentEye::MainWindow::playMedia(), and SilentEye::PropertyDialog::setMedia().
| bool SilentEyeFramework::Media::isDataLoaded | ( | ) | const |
Definition at line 93 of file media.cpp.
References m_isLoaded.
| bool SilentEyeFramework::Media::loadData | ( | ) | [virtual] |
Reimplemented in SEFormatBMP::ImageBMP, SEFormatJPEG::ImageJPEG, SEFormatJPEG::ImageJPEG, and SEFormatWAV::AudioWav.
| bool SilentEyeFramework::Media::saveToDir | ( | QString & | outputDirPath | ) | [virtual] |
Reimplemented in SEFormatBMP::ImageBMP, SEFormatJPEG::ImageJPEG, SEFormatJPEG::ImageJPEG, and SEFormatWAV::AudioWav.
| void SilentEyeFramework::Media::setEncodedData | ( | QPointer< EncodedData > | data | ) |
| void SilentEyeFramework::Media::setShortName | ( | const QString | shortName | ) |
Definition at line 83 of file media.cpp.
References m_shortName, and shortName().
| QString SilentEyeFramework::Media::shortName | ( | ) | const |
Definition at line 78 of file media.cpp.
References m_shortName.
Referenced by Media(), and setShortName().
| Media::Type SilentEyeFramework::Media::type | ( | ) | const |
Definition at line 62 of file media.cpp.
References m_type.
Referenced by SilentEye::MainWindow::playMedia(), SilentEye::PropertyDialog::setMedia(), and SilentEye::MainWindow::stopMedia().
QPointer<EncodedData> SilentEyeFramework::Media::m_data [protected] |
Embedded data.
Definition at line 36 of file media.h.
Referenced by encodedData(), SEFormatBMP::ImageBMP::hideData(), SEFormatWAV::AudioWav::loadData(), SEFormatBMP::ImageBMP::loadData(), Media(), SEFormatWAV::AudioWav::saveToDir(), SEFormatJPEG::ImageJPEG::saveToDir(), and setEncodedData().
QString SilentEyeFramework::Media::m_filePath [protected] |
Media file path.
Definition at line 38 of file media.h.
Referenced by baseName(), computeNewFileName(), filePath(), SEFormatWAV::AudioWav::loadData(), Media(), SilentEyeFramework::Audio::readWaveHeader(), SEFormatWAV::AudioWav::saveToDir(), and SEFormatBMP::ImageBMP::saveToDir().
bool SilentEyeFramework::Media::m_isLoaded [protected] |
Indicate when Media contains some data.
Definition at line 42 of file media.h.
Referenced by isDataLoaded(), SEFormatWAV::AudioWav::loadData(), SEFormatBMP::ImageBMP::loadData(), Media(), and SEFormatBMP::ImageBMP::setNbBits().
QString SilentEyeFramework::Media::m_shortName [protected] |
Media name.
Definition at line 40 of file media.h.
Referenced by computeNewFileName(), Media(), SEFormatWAV::AudioWav::saveToDir(), SEFormatBMP::ImageBMP::saveToDir(), setShortName(), and shortName().
Type SilentEyeFramework::Media::m_type [protected] |
1.7.3