mirror of https://github.com/odrling/Aegisub
Document a few things and kill all remaining placeholders
This commit is contained in:
parent
3949ccec24
commit
009518271a
|
@ -33,7 +33,6 @@
|
||||||
|
|
||||||
|
|
||||||
// Sanity check
|
// Sanity check
|
||||||
|
|
||||||
#ifndef HAVE_LITTLE_ENDIAN
|
#ifndef HAVE_LITTLE_ENDIAN
|
||||||
# ifndef HAVE_BIG_ENDIAN
|
# ifndef HAVE_BIG_ENDIAN
|
||||||
// We neither have big nor little endian from configuration
|
// We neither have big nor little endian from configuration
|
||||||
|
@ -41,23 +40,15 @@
|
||||||
// But this is an OS X system building a universal binary
|
// But this is an OS X system building a universal binary
|
||||||
// Apple's GCC defines _BIG_ENDIAN when building for PPC
|
// Apple's GCC defines _BIG_ENDIAN when building for PPC
|
||||||
# ifdef _BIG_ENDIAN
|
# ifdef _BIG_ENDIAN
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
# define HAVE_BIG_ENDIAN
|
# define HAVE_BIG_ENDIAN
|
||||||
# else
|
# else
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
# define HAVE_LITTLE_ENDIAN
|
# define HAVE_LITTLE_ENDIAN
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
# undef HAVE_DYNAMIC_ENDIAN
|
# undef HAVE_DYNAMIC_ENDIAN
|
||||||
# else // !HAVE_UNIVERSAL_ENDIAN
|
# else // !HAVE_UNIVERSAL_ENDIAN
|
||||||
// We aren't building an OS X universal binary
|
// We aren't building an OS X universal binary
|
||||||
// Use the dynamic endian code
|
// Use the dynamic endian code
|
||||||
# ifndef HAVE_DYNAMIC_ENDIAN
|
# ifndef HAVE_DYNAMIC_ENDIAN
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
# define HAVE_DYNAMIC_ENDIAN
|
# define HAVE_DYNAMIC_ENDIAN
|
||||||
# endif
|
# endif
|
||||||
# endif //HAVE_UNIVERSAL_ENDIAN
|
# endif //HAVE_UNIVERSAL_ENDIAN
|
||||||
|
@ -72,20 +63,11 @@
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
namespace Endian {
|
namespace Endian {
|
||||||
|
|
||||||
// Unconditionally reverse endianness
|
// Unconditionally reverse endianness
|
||||||
|
|
||||||
// These are only defined for unsigned ints,
|
// These are only defined for unsigned ints,
|
||||||
// Use reinterpret_cast on the values if you need signed values.
|
// Use reinterpret_cast on the values if you need signed values.
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint16_t Reverse(uint16_t val)
|
inline uint16_t Reverse(uint16_t val)
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
|
@ -93,11 +75,6 @@ namespace Endian {
|
||||||
((val & 0xFF00) >> 8);
|
((val & 0xFF00) >> 8);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint32_t Reverse(uint32_t val)
|
inline uint32_t Reverse(uint32_t val)
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
|
@ -107,11 +84,6 @@ namespace Endian {
|
||||||
((val & 0xFF000000) >> 24);
|
((val & 0xFF000000) >> 24);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint64_t Reverse(uint64_t val)
|
inline uint64_t Reverse(uint64_t val)
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
|
@ -129,11 +101,7 @@ namespace Endian {
|
||||||
#ifndef HAVE_DYNAMIC_ENDIAN
|
#ifndef HAVE_DYNAMIC_ENDIAN
|
||||||
// Regular, fast, templatized conditional reversing
|
// Regular, fast, templatized conditional reversing
|
||||||
|
|
||||||
/// @brief DOCME
|
template<class T>
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
template <class T>
|
|
||||||
inline T LittleToMachine(T val)
|
inline T LittleToMachine(T val)
|
||||||
{
|
{
|
||||||
#ifdef HAVE_BIG_ENDIAN
|
#ifdef HAVE_BIG_ENDIAN
|
||||||
|
@ -145,11 +113,7 @@ namespace Endian {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief DOCME
|
template<class T>
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
template <class T>
|
|
||||||
inline T BigToMachine(T val)
|
inline T BigToMachine(T val)
|
||||||
{
|
{
|
||||||
#ifdef HAVE_LITTLE_ENDIAN
|
#ifdef HAVE_LITTLE_ENDIAN
|
||||||
|
@ -161,11 +125,7 @@ namespace Endian {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief DOCME
|
template<class T>
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
template <class T>
|
|
||||||
inline T MachineToLittle(T val)
|
inline T MachineToLittle(T val)
|
||||||
{
|
{
|
||||||
#ifdef HAVE_BIG_ENDIAN
|
#ifdef HAVE_BIG_ENDIAN
|
||||||
|
@ -177,11 +137,7 @@ namespace Endian {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief DOCME
|
template<class T>
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
template <class T>
|
|
||||||
inline T MachineToBig(T val)
|
inline T MachineToBig(T val)
|
||||||
{
|
{
|
||||||
#ifdef HAVE_LITTLE_ENDIAN
|
#ifdef HAVE_LITTLE_ENDIAN
|
||||||
|
@ -206,41 +162,23 @@ namespace Endian {
|
||||||
|
|
||||||
// Unions to pack together ints and get their physical bytes
|
// Unions to pack together ints and get their physical bytes
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
union bytes16 {
|
union bytes16 {
|
||||||
/// DOCME
|
|
||||||
uint8_t byte[2];
|
uint8_t byte[2];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
uint16_t word;
|
uint16_t word;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
union bytes32 {
|
union bytes32 {
|
||||||
/// DOCME
|
|
||||||
uint8_t byte[4];
|
uint8_t byte[4];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
uint32_t word;
|
uint32_t word;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
union bytes64 {
|
union bytes64 {
|
||||||
/// DOCME
|
|
||||||
uint8_t byte[8];
|
uint8_t byte[8];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
uint64_t word;
|
uint64_t word;
|
||||||
};
|
};
|
||||||
|
|
||||||
// 16 bit words
|
// 16 bit words
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint16_t MachineToBig(uint16_t val)
|
inline uint16_t MachineToBig(uint16_t val)
|
||||||
{
|
{
|
||||||
bytes16 pack;
|
bytes16 pack;
|
||||||
|
@ -251,11 +189,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint16_t MachineToLittle(uint16_t val)
|
inline uint16_t MachineToLittle(uint16_t val)
|
||||||
{
|
{
|
||||||
bytes16 pack;
|
bytes16 pack;
|
||||||
|
@ -266,11 +199,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint16_t BigToMachine(uint16_t val)
|
inline uint16_t BigToMachine(uint16_t val)
|
||||||
{
|
{
|
||||||
bytes16 pack;
|
bytes16 pack;
|
||||||
|
@ -280,11 +208,6 @@ namespace Endian {
|
||||||
return uint16_t(pack.byte[1]) | (uint16_t(pack.byte[0]) << 8);
|
return uint16_t(pack.byte[1]) | (uint16_t(pack.byte[0]) << 8);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint16_t LittleToMachine(uint16_t val)
|
inline uint16_t LittleToMachine(uint16_t val)
|
||||||
{
|
{
|
||||||
bytes16 pack;
|
bytes16 pack;
|
||||||
|
@ -297,11 +220,6 @@ namespace Endian {
|
||||||
|
|
||||||
// 32 bit words
|
// 32 bit words
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint32_t MachineToBig(uint32_t val)
|
inline uint32_t MachineToBig(uint32_t val)
|
||||||
{
|
{
|
||||||
bytes32 pack;
|
bytes32 pack;
|
||||||
|
@ -312,11 +230,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint32_t MachineToLittle(uint32_t val)
|
inline uint32_t MachineToLittle(uint32_t val)
|
||||||
{
|
{
|
||||||
bytes32 pack;
|
bytes32 pack;
|
||||||
|
@ -327,11 +240,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint32_t BigToMachine(uint32_t val)
|
inline uint32_t BigToMachine(uint32_t val)
|
||||||
{
|
{
|
||||||
bytes32 pack;
|
bytes32 pack;
|
||||||
|
@ -343,11 +251,6 @@ namespace Endian {
|
||||||
uint32_t(pack.byte[3]);
|
uint32_t(pack.byte[3]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint32_t LittleToMachine(uint32_t val)
|
inline uint32_t LittleToMachine(uint32_t val)
|
||||||
{
|
{
|
||||||
bytes32 pack;
|
bytes32 pack;
|
||||||
|
@ -362,11 +265,6 @@ namespace Endian {
|
||||||
|
|
||||||
// 64 bit words
|
// 64 bit words
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint64_t MachineToBig(uint64_t val)
|
inline uint64_t MachineToBig(uint64_t val)
|
||||||
{
|
{
|
||||||
bytes64 pack;
|
bytes64 pack;
|
||||||
|
@ -381,11 +279,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint64_t MachineToLittle(uint64_t val)
|
inline uint64_t MachineToLittle(uint64_t val)
|
||||||
{
|
{
|
||||||
bytes64 pack;
|
bytes64 pack;
|
||||||
|
@ -400,11 +293,6 @@ namespace Endian {
|
||||||
return pack.word;
|
return pack.word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
inline uint64_t BigToMachine(uint64_t val)
|
inline uint64_t BigToMachine(uint64_t val)
|
||||||
{
|
{
|
||||||
bytes64 pack;
|
bytes64 pack;
|
||||||
|
@ -420,10 +308,6 @@ namespace Endian {
|
||||||
uint64_t(pack.byte[7]);
|
uint64_t(pack.byte[7]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param val
|
|
||||||
///
|
|
||||||
inline uint64_t LittleToMachine(uint64_t val)
|
inline uint64_t LittleToMachine(uint64_t val)
|
||||||
{
|
{
|
||||||
bytes64 pack;
|
bytes64 pack;
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
class wxTranslations;
|
class wxTranslations;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AegisubLocale
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AegisubLocale {
|
class AegisubLocale {
|
||||||
wxString active_language;
|
wxString active_language;
|
||||||
wxTranslations *GetTranslations();
|
wxTranslations *GetTranslations();
|
||||||
|
|
|
@ -38,7 +38,6 @@
|
||||||
#include "ass_entry.h"
|
#include "ass_entry.h"
|
||||||
|
|
||||||
/// @class AssAttachment
|
/// @class AssAttachment
|
||||||
/// @brief DOCME
|
|
||||||
class AssAttachment : public AssEntry {
|
class AssAttachment : public AssEntry {
|
||||||
/// Decoded file data
|
/// Decoded file data
|
||||||
std::shared_ptr<std::vector<char> > data;
|
std::shared_ptr<std::vector<char> > data;
|
||||||
|
|
|
@ -47,11 +47,6 @@ namespace agi { struct Context; }
|
||||||
|
|
||||||
typedef std::vector<AssExportFilter*> FilterList;
|
typedef std::vector<AssExportFilter*> FilterList;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssExportFilterChain
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssExportFilterChain {
|
class AssExportFilterChain {
|
||||||
static FilterList *filters();
|
static FilterList *filters();
|
||||||
public:
|
public:
|
||||||
|
@ -68,11 +63,6 @@ public:
|
||||||
static const FilterList *GetFilterList();
|
static const FilterList *GetFilterList();
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssExportFilter
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssExportFilter {
|
class AssExportFilter {
|
||||||
/// The filter chain needs to be able to muck around with filter names when
|
/// The filter chain needs to be able to muck around with filter names when
|
||||||
/// they're registered to avoid duplicates
|
/// they're registered to avoid duplicates
|
||||||
|
|
|
@ -45,11 +45,6 @@ namespace agi { struct Context; }
|
||||||
|
|
||||||
typedef std::vector<AssExportFilter*> FilterList;
|
typedef std::vector<AssExportFilter*> FilterList;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssExporter
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssExporter {
|
class AssExporter {
|
||||||
typedef FilterList::const_iterator filter_iterator;
|
typedef FilterList::const_iterator filter_iterator;
|
||||||
|
|
||||||
|
|
|
@ -53,11 +53,6 @@ typedef boost::intrusive::make_list<AssEntry, boost::intrusive::constant_time_si
|
||||||
typedef EntryList::iterator entryIter;
|
typedef EntryList::iterator entryIter;
|
||||||
typedef EntryList::const_iterator constEntryIter;
|
typedef EntryList::const_iterator constEntryIter;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssFile
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssFile {
|
class AssFile {
|
||||||
boost::container::list<AssFile> UndoStack;
|
boost::container::list<AssFile> UndoStack;
|
||||||
boost::container::list<AssFile> RedoStack;
|
boost::container::list<AssFile> RedoStack;
|
||||||
|
|
|
@ -65,9 +65,7 @@ enum AssParameterOptional {
|
||||||
OPTIONAL_7 = 0x40
|
OPTIONAL_7 = 0x40
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
/// A single parameter to an override tag
|
||||||
/// @class AssOverrideParameter
|
|
||||||
/// @brief A single parameter to an override tag
|
|
||||||
class AssOverrideParameter : public VariableData {
|
class AssOverrideParameter : public VariableData {
|
||||||
public:
|
public:
|
||||||
/// Type of parameter
|
/// Type of parameter
|
||||||
|
@ -81,9 +79,7 @@ public:
|
||||||
void operator=(const AssOverrideParameter ¶m);
|
void operator=(const AssOverrideParameter ¶m);
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
/// Prototype of a single override parameter
|
||||||
/// @class AssOverrideParamProto
|
|
||||||
/// @brief Prototype of a single override parameter
|
|
||||||
struct AssOverrideParamProto {
|
struct AssOverrideParamProto {
|
||||||
/// ASS_ParameterOptional
|
/// ASS_ParameterOptional
|
||||||
int optional;
|
int optional;
|
||||||
|
@ -97,9 +93,6 @@ struct AssOverrideParamProto {
|
||||||
AssOverrideParamProto (VariableDataType type, int opt=NOT_OPTIONAL, AssParameterClass classi=PARCLASS_NORMAL);
|
AssOverrideParamProto (VariableDataType type, int opt=NOT_OPTIONAL, AssParameterClass classi=PARCLASS_NORMAL);
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssOverrideTagProto
|
|
||||||
/// @brief DOCME
|
|
||||||
struct AssOverrideTagProto {
|
struct AssOverrideTagProto {
|
||||||
/// Name of the tag, with slash
|
/// Name of the tag, with slash
|
||||||
wxString name;
|
wxString name;
|
||||||
|
@ -120,17 +113,12 @@ struct AssOverrideTagProto {
|
||||||
void Set(wxString name, VariableDataType type, AssParameterClass classi = PARCLASS_NORMAL, int opt = NOT_OPTIONAL);
|
void Set(wxString name, VariableDataType type, AssParameterClass classi = PARCLASS_NORMAL, int opt = NOT_OPTIONAL);
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssOverrideTag
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssOverrideTag {
|
class AssOverrideTag {
|
||||||
bool valid;
|
bool valid;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
wxString Name;
|
wxString Name;
|
||||||
std::vector <AssOverrideParameter*> Params;
|
std::vector<AssOverrideParameter*> Params;
|
||||||
|
|
||||||
AssOverrideTag();
|
AssOverrideTag();
|
||||||
AssOverrideTag(wxString text);
|
AssOverrideTag(wxString text);
|
||||||
|
|
|
@ -38,11 +38,6 @@
|
||||||
|
|
||||||
class AssStyle;
|
class AssStyle;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssStyleStorage
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssStyleStorage {
|
class AssStyleStorage {
|
||||||
wxString storage_name;
|
wxString storage_name;
|
||||||
std::deque<AssStyle*> style;
|
std::deque<AssStyle*> style;
|
||||||
|
|
|
@ -38,11 +38,6 @@
|
||||||
|
|
||||||
#include <libaegisub/vfr.h>
|
#include <libaegisub/vfr.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AssTime
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssTime {
|
class AssTime {
|
||||||
/// Time in milliseconds
|
/// Time in milliseconds
|
||||||
int time;
|
int time;
|
||||||
|
|
|
@ -69,13 +69,8 @@ class AudioBox : public wxSashWindow {
|
||||||
/// The audio display in the box
|
/// The audio display in the box
|
||||||
AudioDisplay *audioDisplay;
|
AudioDisplay *audioDisplay;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSlider *HorizontalZoom;
|
wxSlider *HorizontalZoom;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSlider *VerticalZoom;
|
wxSlider *VerticalZoom;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSlider *VolumeBar;
|
wxSlider *VolumeBar;
|
||||||
|
|
||||||
// Mouse wheel zoom accumulator
|
// Mouse wheel zoom accumulator
|
||||||
|
|
|
@ -43,18 +43,8 @@
|
||||||
|
|
||||||
class DirectSoundPlayer;
|
class DirectSoundPlayer;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DirectSoundPlayerThread
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DirectSoundPlayerThread : public wxThread {
|
class DirectSoundPlayerThread : public wxThread {
|
||||||
private:
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
DirectSoundPlayer *parent;
|
DirectSoundPlayer *parent;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
HANDLE stopnotify;
|
HANDLE stopnotify;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -65,49 +55,23 @@ public:
|
||||||
wxThread::ExitCode Entry();
|
wxThread::ExitCode Entry();
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DirectSoundPlayer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DirectSoundPlayer : public AudioPlayer {
|
class DirectSoundPlayer : public AudioPlayer {
|
||||||
friend class DirectSoundPlayerThread;
|
friend class DirectSoundPlayerThread;
|
||||||
|
|
||||||
private:
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile bool playing;
|
volatile bool playing;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
float volume;
|
float volume;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int offset;
|
int offset;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
DWORD bufSize;
|
DWORD bufSize;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile int64_t playPos;
|
volatile int64_t playPos;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int64_t startPos;
|
int64_t startPos;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile int64_t endPos;
|
volatile int64_t endPos;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
DWORD startTime;
|
DWORD startTime;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
IDirectSound8 *directSound;
|
IDirectSound8 *directSound;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
IDirectSoundBuffer8 *buffer;
|
IDirectSoundBuffer8 *buffer;
|
||||||
|
|
||||||
bool FillBuffer(bool fill);
|
bool FillBuffer(bool fill);
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
DirectSoundPlayerThread *thread;
|
DirectSoundPlayerThread *thread;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -51,11 +51,6 @@
|
||||||
|
|
||||||
#include <wx/timer.h>
|
#include <wx/timer.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class OpenALPlayer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class OpenALPlayer : public AudioPlayer, wxTimer {
|
class OpenALPlayer : public AudioPlayer, wxTimer {
|
||||||
/// Number of OpenAL buffers to use
|
/// Number of OpenAL buffers to use
|
||||||
static const ALsizei num_buffers = 8;
|
static const ALsizei num_buffers = 8;
|
||||||
|
@ -87,7 +82,6 @@ class OpenALPlayer : public AudioPlayer, wxTimer {
|
||||||
/// Number of buffers which have been fully played since playback was last started
|
/// Number of buffers which have been fully played since playback was last started
|
||||||
ALsizei buffers_played;
|
ALsizei buffers_played;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxStopWatch playback_segment_timer;
|
wxStopWatch playback_segment_timer;
|
||||||
|
|
||||||
/// Buffer to decode audio into
|
/// Buffer to decode audio into
|
||||||
|
|
|
@ -51,9 +51,7 @@
|
||||||
class AudioProvider;
|
class AudioProvider;
|
||||||
class OSSPlayer;
|
class OSSPlayer;
|
||||||
|
|
||||||
/// DOCME
|
/// Worker thread to asynchronously write audio data to the output device
|
||||||
/// @class OSSPlayerThread
|
|
||||||
/// @brief Worker thread to asynchronously write audio data to the output device
|
|
||||||
class OSSPlayerThread : public wxThread {
|
class OSSPlayerThread : public wxThread {
|
||||||
/// Parent player
|
/// Parent player
|
||||||
OSSPlayer *parent;
|
OSSPlayer *parent;
|
||||||
|
@ -67,11 +65,6 @@ public:
|
||||||
wxThread::ExitCode Entry();
|
wxThread::ExitCode Entry();
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class OSSPlayer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class OSSPlayer : public AudioPlayer {
|
class OSSPlayer : public AudioPlayer {
|
||||||
friend class OSSPlayerThread;
|
friend class OSSPlayerThread;
|
||||||
|
|
||||||
|
|
|
@ -39,81 +39,45 @@
|
||||||
|
|
||||||
class PulseAudioPlayer;
|
class PulseAudioPlayer;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class PulseAudioPlayer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class PulseAudioPlayer : public AudioPlayer {
|
class PulseAudioPlayer : public AudioPlayer {
|
||||||
/// DOCME
|
|
||||||
float volume;
|
float volume;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool is_playing;
|
bool is_playing;
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile unsigned long start_frame;
|
volatile unsigned long start_frame;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile unsigned long cur_frame;
|
volatile unsigned long cur_frame;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile unsigned long end_frame;
|
volatile unsigned long end_frame;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
unsigned long bpf; // bytes per frame
|
unsigned long bpf; // bytes per frame
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSemaphore context_notify;
|
wxSemaphore context_notify;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSemaphore context_success;
|
wxSemaphore context_success;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile int context_success_val;
|
volatile int context_success_val;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSemaphore stream_notify;
|
wxSemaphore stream_notify;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSemaphore stream_success;
|
wxSemaphore stream_success;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile int stream_success_val;
|
volatile int stream_success_val;
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
pa_threaded_mainloop *mainloop; // pulseaudio mainloop handle
|
pa_threaded_mainloop *mainloop; // pulseaudio mainloop handle
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
pa_context *context; // connection context
|
pa_context *context; // connection context
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile pa_context_state_t cstate;
|
volatile pa_context_state_t cstate;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
pa_stream *stream;
|
pa_stream *stream;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile pa_stream_state_t sstate;
|
volatile pa_stream_state_t sstate;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
volatile pa_usec_t play_start_time; // timestamp when playback was started
|
volatile pa_usec_t play_start_time; // timestamp when playback was started
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int paerror;
|
int paerror;
|
||||||
|
|
||||||
// Called by PA to notify about contetxt operation completion
|
/// Called by PA to notify about contetxt operation completion
|
||||||
static void pa_context_success(pa_context *c, int success, PulseAudioPlayer *thread);
|
static void pa_context_success(pa_context *c, int success, PulseAudioPlayer *thread);
|
||||||
// Called by PA to notify about other context-related stuff
|
/// Called by PA to notify about other context-related stuff
|
||||||
static void pa_context_notify(pa_context *c, PulseAudioPlayer *thread);
|
static void pa_context_notify(pa_context *c, PulseAudioPlayer *thread);
|
||||||
// Called by PA when a stream operation completes
|
/// Called by PA when a stream operation completes
|
||||||
static void pa_stream_success(pa_stream *p, int success, PulseAudioPlayer *thread);
|
static void pa_stream_success(pa_stream *p, int success, PulseAudioPlayer *thread);
|
||||||
// Called by PA to request more data written to stream
|
/// Called by PA to request more data written to stream
|
||||||
static void pa_stream_write(pa_stream *p, size_t length, PulseAudioPlayer *thread);
|
static void pa_stream_write(pa_stream *p, size_t length, PulseAudioPlayer *thread);
|
||||||
// Called by PA to notify about other stream-related stuff
|
/// Called by PA to notify about other stream-related stuff
|
||||||
static void pa_stream_notify(pa_stream *p, PulseAudioPlayer *thread);
|
static void pa_stream_notify(pa_stream *p, PulseAudioPlayer *thread);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -38,19 +38,10 @@
|
||||||
#include "avisynth.h"
|
#include "avisynth.h"
|
||||||
#include "avisynth_wrap.h"
|
#include "avisynth_wrap.h"
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AvisynthAudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AvisynthAudioProvider : public AudioProvider {
|
class AvisynthAudioProvider : public AudioProvider {
|
||||||
AviSynthWrapper avs_wrapper;
|
AviSynthWrapper avs_wrapper;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxString filename;
|
wxString filename;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
PClip clip;
|
PClip clip;
|
||||||
|
|
||||||
void LoadFromClip(AVSValue clip);
|
void LoadFromClip(AVSValue clip);
|
||||||
|
|
|
@ -34,13 +34,7 @@
|
||||||
|
|
||||||
#include "include/aegisub/audio_provider.h"
|
#include "include/aegisub/audio_provider.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DummyAudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DummyAudioProvider : public AudioProvider {
|
class DummyAudioProvider : public AudioProvider {
|
||||||
/// DOCME
|
|
||||||
bool noise;
|
bool noise;
|
||||||
void FillBuffer(void *buf, int64_t start, int64_t count) const;
|
void FillBuffer(void *buf, int64_t start, int64_t count) const;
|
||||||
|
|
||||||
|
|
|
@ -43,11 +43,6 @@ namespace agi {
|
||||||
class ProgressSink;
|
class ProgressSink;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class HDAudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class HDAudioProvider : public AudioProvider {
|
class HDAudioProvider : public AudioProvider {
|
||||||
/// Name of the file which the decoded audio is written to
|
/// Name of the file which the decoded audio is written to
|
||||||
wxString diskCacheFilename;
|
wxString diskCacheFilename;
|
||||||
|
|
|
@ -214,13 +214,11 @@ void PCMAudioProvider::FillBuffer(void *buf, int64_t start, int64_t count) const
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class RiffWavPCMAudioProvider
|
/// @class RiffWavPCMAudioProvider
|
||||||
/// @brief RIFF WAV PCM provider
|
/// @brief RIFF WAV PCM provider
|
||||||
///
|
///
|
||||||
/// Overview of RIFF WAV: <http://www.sonicspot.com/guide/wavefiles.html>
|
/// Overview of RIFF WAV: <http://www.sonicspot.com/guide/wavefiles.html>
|
||||||
class RiffWavPCMAudioProvider : public PCMAudioProvider {
|
class RiffWavPCMAudioProvider : public PCMAudioProvider {
|
||||||
/// DOCME
|
|
||||||
struct ChunkHeader {
|
struct ChunkHeader {
|
||||||
/// Always "RIFF"
|
/// Always "RIFF"
|
||||||
char type[4];
|
char type[4];
|
||||||
|
@ -228,19 +226,13 @@ class RiffWavPCMAudioProvider : public PCMAudioProvider {
|
||||||
uint32_t size;
|
uint32_t size;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
struct RIFFChunk {
|
struct RIFFChunk {
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ChunkHeader ch;
|
ChunkHeader ch;
|
||||||
|
|
||||||
/// Always "WAVE"
|
/// Always "WAVE"
|
||||||
char format[4];
|
char format[4];
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
struct fmtChunk {
|
struct fmtChunk {
|
||||||
|
|
||||||
/// compression format used
|
/// compression format used
|
||||||
/// We support only PCM (0x1)
|
/// We support only PCM (0x1)
|
||||||
uint16_t compression;
|
uint16_t compression;
|
||||||
|
@ -383,7 +375,6 @@ static const uint8_t w64Guiddata[16] = {
|
||||||
0x64, 0x61, 0x74, 0x61, 0xF3, 0xAC, 0xD3, 0x11, 0x8C, 0xD1, 0x00, 0xC0, 0x4F, 0x8E, 0xDB, 0x8A
|
0x64, 0x61, 0x74, 0x61, 0xF3, 0xAC, 0xD3, 0x11, 0x8C, 0xD1, 0x00, 0xC0, 0x4F, 0x8E, 0xDB, 0x8A
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class Wave64AudioProvider
|
/// @class Wave64AudioProvider
|
||||||
/// @brief Sony Wave64 audio provider
|
/// @brief Sony Wave64 audio provider
|
||||||
///
|
///
|
||||||
|
|
|
@ -46,11 +46,6 @@
|
||||||
|
|
||||||
#include <libaegisub/scoped_ptr.h>
|
#include <libaegisub/scoped_ptr.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class PCMAudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class PCMAudioProvider : public AudioProvider {
|
class PCMAudioProvider : public AudioProvider {
|
||||||
mutable void *current_mapping;
|
mutable void *current_mapping;
|
||||||
|
|
||||||
|
|
|
@ -39,19 +39,9 @@ namespace agi {
|
||||||
class ProgressSink;
|
class ProgressSink;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class RAMAudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class RAMAudioProvider : public AudioProvider {
|
class RAMAudioProvider : public AudioProvider {
|
||||||
/// DOCME
|
|
||||||
char** blockcache;
|
char** blockcache;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int blockcount;
|
int blockcount;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool samples_native_endian;
|
bool samples_native_endian;
|
||||||
|
|
||||||
void Clear();
|
void Clear();
|
||||||
|
|
|
@ -71,7 +71,6 @@
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
namespace Automation4 {
|
namespace Automation4 {
|
||||||
bool CalculateTextExtents(AssStyle *style, wxString const& text, double &width, double &height, double &descent, double &extlead)
|
bool CalculateTextExtents(AssStyle *style, wxString const& text, double &width, double &height, double &descent, double &extlead)
|
||||||
{
|
{
|
||||||
|
|
|
@ -65,8 +65,6 @@ class wxPathList;
|
||||||
namespace agi { struct Context; }
|
namespace agi { struct Context; }
|
||||||
namespace cmd { class Command; }
|
namespace cmd { class Command; }
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
namespace Automation4 {
|
namespace Automation4 {
|
||||||
DEFINE_BASE_EXCEPTION_NOINNER(AutomationError, agi::Exception)
|
DEFINE_BASE_EXCEPTION_NOINNER(AutomationError, agi::Exception)
|
||||||
DEFINE_SIMPLE_EXCEPTION_NOINNER(ScriptLoadError, AutomationError, "automation/load/generic")
|
DEFINE_SIMPLE_EXCEPTION_NOINNER(ScriptLoadError, AutomationError, "automation/load/generic")
|
||||||
|
|
|
@ -35,11 +35,6 @@
|
||||||
#include "auto4_base.h"
|
#include "auto4_base.h"
|
||||||
|
|
||||||
namespace Automation4 {
|
namespace Automation4 {
|
||||||
/// DOCME
|
|
||||||
/// @class LuaScriptFactory
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class LuaScriptFactory : public ScriptFactory {
|
class LuaScriptFactory : public ScriptFactory {
|
||||||
Script* Produce(const wxString &filename) const;
|
Script* Produce(const wxString &filename) const;
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
class IScriptEnvironment;
|
class IScriptEnvironment;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AviSynthWrapper
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AviSynthWrapper {
|
class AviSynthWrapper {
|
||||||
AviSynthWrapper(AviSynthWrapper const&);
|
AviSynthWrapper(AviSynthWrapper const&);
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -51,11 +51,6 @@ namespace agi {
|
||||||
}
|
}
|
||||||
class AssDialogue;
|
class AssDialogue;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class BaseGrid
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class BaseGrid : public wxWindow, public SubtitleSelectionController {
|
class BaseGrid : public wxWindow, public SubtitleSelectionController {
|
||||||
int lineHeight; ///< Height of a line in pixels in the current font
|
int lineHeight; ///< Height of a line in pixels in the current font
|
||||||
bool holding; ///< Is a drag selection in process?
|
bool holding; ///< Is a drag selection in process?
|
||||||
|
|
|
@ -98,7 +98,6 @@ class DataBlockCache {
|
||||||
/// Type of an array of blocks
|
/// Type of an array of blocks
|
||||||
typedef std::vector<BlockT*> BlockArray;
|
typedef std::vector<BlockT*> BlockArray;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
struct MacroBlock {
|
struct MacroBlock {
|
||||||
/// This macroblock's position in the age list
|
/// This macroblock's position in the age list
|
||||||
/// Is valid iff blocks.size() > 0
|
/// Is valid iff blocks.size() > 0
|
||||||
|
|
|
@ -41,21 +41,11 @@ class wxListEvent;
|
||||||
|
|
||||||
#include "ass_entry.h"
|
#include "ass_entry.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogAttachments
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogAttachments : public wxDialog {
|
class DialogAttachments : public wxDialog {
|
||||||
AssFile *ass;
|
AssFile *ass;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxListView *listView;
|
wxListView *listView;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxButton *extractButton;
|
wxButton *extractButton;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxButton *deleteButton;
|
wxButton *deleteButton;
|
||||||
|
|
||||||
void OnAttachFont(wxCommandEvent &event);
|
void OnAttachFont(wxCommandEvent &event);
|
||||||
|
|
|
@ -50,11 +50,6 @@ class wxButton;
|
||||||
class wxListEvent;
|
class wxListEvent;
|
||||||
class wxListView;
|
class wxListView;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogAutomation
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogAutomation : public wxDialog {
|
class DialogAutomation : public wxDialog {
|
||||||
agi::Context *context;
|
agi::Context *context;
|
||||||
|
|
||||||
|
|
|
@ -190,16 +190,13 @@ class DialogColorPicker : public wxDialog {
|
||||||
/// click the eyedropper or drag the eyedropper
|
/// click the eyedropper or drag the eyedropper
|
||||||
wxPoint eyedropper_grab_point;
|
wxPoint eyedropper_grab_point;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool eyedropper_is_grabbed;
|
bool eyedropper_is_grabbed;
|
||||||
|
|
||||||
wxStaticBitmap *preview_box; ///< A box which simply shows the current color
|
wxStaticBitmap *preview_box; ///< A box which simply shows the current color
|
||||||
ColorPickerRecent *recent_box; ///< A grid of recently used colors
|
ColorPickerRecent *recent_box; ///< A grid of recently used colors
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ColorPickerScreenDropper *screen_dropper;
|
ColorPickerScreenDropper *screen_dropper;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxStaticBitmap *screen_dropper_icon;
|
wxStaticBitmap *screen_dropper_icon;
|
||||||
|
|
||||||
/// Update all other controls as a result of modifying an RGB control
|
/// Update all other controls as a result of modifying an RGB control
|
||||||
|
|
|
@ -42,11 +42,6 @@ class PersistLocation;
|
||||||
class VideoBox;
|
class VideoBox;
|
||||||
class VideoDisplay;
|
class VideoDisplay;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogDetachedVideo
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogDetachedVideo : public wxDialog {
|
class DialogDetachedVideo : public wxDialog {
|
||||||
agi::Context *context;
|
agi::Context *context;
|
||||||
VideoDisplay *old_display;
|
VideoDisplay *old_display;
|
||||||
|
|
|
@ -64,14 +64,12 @@ enum {
|
||||||
Dummy_Video_Length
|
Dummy_Video_Length
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
struct ResolutionShortcut {
|
struct ResolutionShortcut {
|
||||||
const char *name;
|
const char *name;
|
||||||
int width;
|
int width;
|
||||||
int height;
|
int height;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
static ResolutionShortcut resolutions[] = {
|
static ResolutionShortcut resolutions[] = {
|
||||||
{"640x480 (SD fullscreen)", 640, 480},
|
{"640x480 (SD fullscreen)", 640, 480},
|
||||||
{"704x480 (SD anamorphic)", 704, 480},
|
{"704x480 (SD anamorphic)", 704, 480},
|
||||||
|
|
|
@ -42,11 +42,6 @@ class wxSpinCtrl;
|
||||||
class wxStaticText;
|
class wxStaticText;
|
||||||
class wxTextCtrl;
|
class wxTextCtrl;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogDummyVideo
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogDummyVideo : public wxDialog {
|
class DialogDummyVideo : public wxDialog {
|
||||||
DialogDummyVideo(wxWindow *parent);
|
DialogDummyVideo(wxWindow *parent);
|
||||||
~DialogDummyVideo();
|
~DialogDummyVideo();
|
||||||
|
|
|
@ -47,11 +47,6 @@
|
||||||
class AssExporter;
|
class AssExporter;
|
||||||
namespace agi { struct Context; }
|
namespace agi { struct Context; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogExport
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogExport : public wxDialog {
|
class DialogExport : public wxDialog {
|
||||||
agi::Context *c;
|
agi::Context *c;
|
||||||
|
|
||||||
|
@ -67,7 +62,6 @@ class DialogExport : public wxDialog {
|
||||||
/// A list of available target charsets
|
/// A list of available target charsets
|
||||||
wxChoice *charset_list;
|
wxChoice *charset_list;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSizer *opt_sizer;
|
wxSizer *opt_sizer;
|
||||||
|
|
||||||
void OnProcess(wxCommandEvent &);
|
void OnProcess(wxCommandEvent &);
|
||||||
|
|
|
@ -31,11 +31,6 @@ class wxStaticText;
|
||||||
class wxTextCtrl;
|
class wxTextCtrl;
|
||||||
class wxThreadEvent;
|
class wxThreadEvent;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogFontsCollector
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogFontsCollector : public wxDialog {
|
class DialogFontsCollector : public wxDialog {
|
||||||
AssFile *subs;
|
AssFile *subs;
|
||||||
|
|
||||||
|
|
|
@ -35,11 +35,6 @@
|
||||||
class TimeEdit;
|
class TimeEdit;
|
||||||
namespace agi { struct Context; }
|
namespace agi { struct Context; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogJumpTo
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogJumpTo : public wxDialog {
|
class DialogJumpTo : public wxDialog {
|
||||||
agi::Context *c; ///< Project context
|
agi::Context *c; ///< Project context
|
||||||
long jumpframe; ///< Target frame to jump to
|
long jumpframe; ///< Target frame to jump to
|
||||||
|
|
|
@ -75,11 +75,6 @@ enum {
|
||||||
BUTTON_KTACCEPT
|
BUTTON_KTACCEPT
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class KaraokeLineMatchDisplay
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class KaraokeLineMatchDisplay : public wxControl {
|
class KaraokeLineMatchDisplay : public wxControl {
|
||||||
typedef AssKaraoke::Syllable MatchSyllable;
|
typedef AssKaraoke::Syllable MatchSyllable;
|
||||||
|
|
||||||
|
|
|
@ -45,11 +45,6 @@ class KaraokeLineMatchDisplay;
|
||||||
class wxComboBox;
|
class wxComboBox;
|
||||||
class wxCheckBox;
|
class wxCheckBox;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogKanjiTimer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogKanjiTimer : public wxDialog {
|
class DialogKanjiTimer : public wxDialog {
|
||||||
AssFile *subs;
|
AssFile *subs;
|
||||||
|
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
class wxCheckListBox;
|
class wxCheckListBox;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogPasteOver
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogPasteOver : public wxDialog {
|
class DialogPasteOver : public wxDialog {
|
||||||
wxCheckListBox *ListBox;
|
wxCheckListBox *ListBox;
|
||||||
|
|
||||||
|
|
|
@ -41,11 +41,6 @@
|
||||||
class AssFile;
|
class AssFile;
|
||||||
namespace agi { struct Context; }
|
namespace agi { struct Context; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogProperties
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogProperties : public wxDialog {
|
class DialogProperties : public wxDialog {
|
||||||
agi::Context *c; ///< Project this dialog is adjusting the properties of
|
agi::Context *c; ///< Project this dialog is adjusting the properties of
|
||||||
|
|
||||||
|
|
|
@ -28,11 +28,6 @@ class wxRadioBox;
|
||||||
class wxRadioButton;
|
class wxRadioButton;
|
||||||
class wxTextCtrl;
|
class wxTextCtrl;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogSelection
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogSelection : public wxDialog {
|
class DialogSelection : public wxDialog {
|
||||||
agi::Context *con; ///< Project context
|
agi::Context *con; ///< Project context
|
||||||
|
|
||||||
|
|
|
@ -41,11 +41,6 @@ namespace json {
|
||||||
typedef std::deque<UnknownElement> Array;
|
typedef std::deque<UnknownElement> Array;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogShiftTimes
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogShiftTimes : public wxDialog {
|
class DialogShiftTimes : public wxDialog {
|
||||||
agi::Context *context;
|
agi::Context *context;
|
||||||
|
|
||||||
|
|
|
@ -36,11 +36,6 @@ class wxComboBox;
|
||||||
class wxListBox;
|
class wxListBox;
|
||||||
class wxTextCtrl;
|
class wxTextCtrl;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogSpellChecker
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogSpellChecker : public wxDialog {
|
class DialogSpellChecker : public wxDialog {
|
||||||
agi::Context *context; ///< The project context
|
agi::Context *context; ///< The project context
|
||||||
agi::scoped_ptr<agi::SpellChecker> spellchecker; ///< The spellchecking engine
|
agi::scoped_ptr<agi::SpellChecker> spellchecker; ///< The spellchecking engine
|
||||||
|
|
|
@ -47,11 +47,6 @@ class ColourButton;
|
||||||
class PersistLocation;
|
class PersistLocation;
|
||||||
class SubtitlesPreview;
|
class SubtitlesPreview;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogStyleEditor
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogStyleEditor : public wxDialog {
|
class DialogStyleEditor : public wxDialog {
|
||||||
agi::Context *c;
|
agi::Context *c;
|
||||||
agi::scoped_ptr<PersistLocation> persist;
|
agi::scoped_ptr<PersistLocation> persist;
|
||||||
|
@ -61,76 +56,36 @@ class DialogStyleEditor : public wxDialog {
|
||||||
/// the style
|
/// the style
|
||||||
bool is_new;
|
bool is_new;
|
||||||
|
|
||||||
/// DOCME
|
/// The style currently being edited
|
||||||
AssStyle *style;
|
AssStyle *style;
|
||||||
|
|
||||||
/// DOCME
|
/// Copy of style passed to the subtitles preview to avoid making changes
|
||||||
|
/// before Apply is clicked
|
||||||
agi::scoped_ptr<AssStyle> work;
|
agi::scoped_ptr<AssStyle> work;
|
||||||
|
|
||||||
/// DOCME
|
/// The style storage style is in, if applicable
|
||||||
AssStyleStorage *store;
|
AssStyleStorage *store;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *StyleName;
|
wxTextCtrl *StyleName;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxComboBox *FontName;
|
wxComboBox *FontName;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *FontSize;
|
wxTextCtrl *FontSize;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxCheckBox *BoxBold;
|
wxCheckBox *BoxBold;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxCheckBox *BoxItalic;
|
wxCheckBox *BoxItalic;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxCheckBox *BoxUnderline;
|
wxCheckBox *BoxUnderline;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxCheckBox *BoxStrikeout;
|
wxCheckBox *BoxStrikeout;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ColourButton *colorButton[4];
|
ColourButton *colorButton[4];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSpinCtrl *colorAlpha[4];
|
wxSpinCtrl *colorAlpha[4];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxSpinCtrl *margin[3];
|
wxSpinCtrl *margin[3];
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxRadioBox *Alignment;
|
wxRadioBox *Alignment;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *Outline;
|
wxTextCtrl *Outline;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *Shadow;
|
wxTextCtrl *Shadow;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxCheckBox *OutlineType;
|
wxCheckBox *OutlineType;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *ScaleX;
|
wxTextCtrl *ScaleX;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *ScaleY;
|
wxTextCtrl *ScaleY;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *Angle;
|
wxTextCtrl *Angle;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxComboBox *Encoding;
|
wxComboBox *Encoding;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *Spacing;
|
wxTextCtrl *Spacing;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxTextCtrl *PreviewText;
|
wxTextCtrl *PreviewText;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
SubtitlesPreview *SubsPreview;
|
SubtitlesPreview *SubsPreview;
|
||||||
|
|
||||||
void SetBitmapColor(int n,wxColour color);
|
void SetBitmapColor(int n,wxColour color);
|
||||||
|
|
|
@ -51,11 +51,6 @@ class AssStyle;
|
||||||
class DialogStyleEditor;
|
class DialogStyleEditor;
|
||||||
class PersistLocation;
|
class PersistLocation;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogStyleManager
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogStyleManager : public wxDialog {
|
class DialogStyleManager : public wxDialog {
|
||||||
agi::Context *c; ///< Project context
|
agi::Context *c; ///< Project context
|
||||||
agi::scoped_ptr<PersistLocation> persist;
|
agi::scoped_ptr<PersistLocation> persist;
|
||||||
|
|
|
@ -34,11 +34,6 @@ class wxCheckBox;
|
||||||
class wxListBox;
|
class wxListBox;
|
||||||
class wxTextCtrl;
|
class wxTextCtrl;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class DialogStyling
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogStyling : public wxDialog {
|
class DialogStyling : public wxDialog {
|
||||||
agi::Context *c;
|
agi::Context *c;
|
||||||
agi::signal::Connection active_line_connection;
|
agi::signal::Connection active_line_connection;
|
||||||
|
|
|
@ -35,10 +35,7 @@ class SubsTextEditCtrl;
|
||||||
class wxStaticText;
|
class wxStaticText;
|
||||||
class wxCheckBox;
|
class wxCheckBox;
|
||||||
|
|
||||||
/// @class DialogTranslation
|
/// Assistant for translating subtitles in one language to another language
|
||||||
/// @brief Assistant for translating subtitles in one language to another language
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class DialogTranslation : public wxDialog {
|
class DialogTranslation : public wxDialog {
|
||||||
agi::Context *c;
|
agi::Context *c;
|
||||||
|
|
||||||
|
|
|
@ -36,20 +36,11 @@
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <cmath>
|
|
||||||
|
|
||||||
#include "fft.h"
|
#include "fft.h"
|
||||||
|
|
||||||
|
#include <cmath>
|
||||||
|
|
||||||
/// @brief Transform
|
|
||||||
/// @param n_samples
|
|
||||||
/// @param input
|
|
||||||
/// @param output_r
|
|
||||||
/// @param output_i
|
|
||||||
/// @param inverse
|
|
||||||
///
|
|
||||||
void FFT::DoTransform (size_t n_samples,float *input,float *output_r,float *output_i,bool inverse) {
|
void FFT::DoTransform (size_t n_samples,float *input,float *output_r,float *output_i,bool inverse) {
|
||||||
// Check if it's power of two
|
|
||||||
if (!IsPowerOfTwo(n_samples)) {
|
if (!IsPowerOfTwo(n_samples)) {
|
||||||
throw "FFT requires power of two input.";
|
throw "FFT requires power of two input.";
|
||||||
}
|
}
|
||||||
|
@ -127,47 +118,22 @@ void FFT::DoTransform (size_t n_samples,float *input,float *output_r,float *outp
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// @brief Transform wrappers
|
|
||||||
/// @param n_samples
|
|
||||||
/// @param input
|
|
||||||
/// @param output_r
|
|
||||||
/// @param output_i
|
|
||||||
///
|
|
||||||
void FFT::Transform(size_t n_samples,float *input,float *output_r,float *output_i) {
|
void FFT::Transform(size_t n_samples,float *input,float *output_r,float *output_i) {
|
||||||
DoTransform(n_samples,input,output_r,output_i,false);
|
DoTransform(n_samples,input,output_r,output_i,false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param n_samples
|
|
||||||
/// @param input
|
|
||||||
/// @param output_r
|
|
||||||
/// @param output_i
|
|
||||||
///
|
|
||||||
void FFT::InverseTransform(size_t n_samples,float *input,float *output_r,float *output_i) {
|
void FFT::InverseTransform(size_t n_samples,float *input,float *output_r,float *output_i) {
|
||||||
DoTransform(n_samples,input,output_r,output_i,true);
|
DoTransform(n_samples,input,output_r,output_i,true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// @brief Checks if number is a power of two
|
/// @brief Checks if number is a power of two
|
||||||
/// @param x
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
bool FFT::IsPowerOfTwo (unsigned int x) {
|
bool FFT::IsPowerOfTwo (unsigned int x) {
|
||||||
if (x < 2) return false;
|
if (x < 2) return false;
|
||||||
if (x & (x-1)) return false;
|
if (x & (x-1)) return false;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// @brief Bits needed by the FFT
|
/// @brief Bits needed by the FFT
|
||||||
/// @param n_samples
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
unsigned int FFT::NumberOfBitsNeeded (unsigned int n_samples) {
|
unsigned int FFT::NumberOfBitsNeeded (unsigned int n_samples) {
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
@ -180,13 +146,7 @@ unsigned int FFT::NumberOfBitsNeeded (unsigned int n_samples) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// @brief Get reversed bit position
|
/// @brief Get reversed bit position
|
||||||
/// @param index
|
|
||||||
/// @param bits
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
unsigned int FFT::ReverseBits (unsigned int index, unsigned int bits) {
|
unsigned int FFT::ReverseBits (unsigned int index, unsigned int bits) {
|
||||||
unsigned int i, rev;
|
unsigned int i, rev;
|
||||||
|
|
||||||
|
@ -198,13 +158,7 @@ unsigned int FFT::ReverseBits (unsigned int index, unsigned int bits) {
|
||||||
return rev;
|
return rev;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// @brief Get frequency at index
|
/// @brief Get frequency at index
|
||||||
/// @param baseFreq
|
|
||||||
/// @param n_samples
|
|
||||||
/// @param index
|
|
||||||
///
|
|
||||||
float FFT::FrequencyAtIndex (unsigned int baseFreq, unsigned int n_samples, unsigned int index) {
|
float FFT::FrequencyAtIndex (unsigned int baseFreq, unsigned int n_samples, unsigned int index) {
|
||||||
if (index >= n_samples) return 0.0;
|
if (index >= n_samples) return 0.0;
|
||||||
else if (index <= n_samples/2) {
|
else if (index <= n_samples/2) {
|
||||||
|
@ -214,5 +168,3 @@ float FFT::FrequencyAtIndex (unsigned int baseFreq, unsigned int n_samples, unsi
|
||||||
return (-(float)(n_samples-index) / (float)n_samples * baseFreq);
|
return (-(float)(n_samples-index) / (float)n_samples * baseFreq);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -32,19 +32,9 @@
|
||||||
/// @ingroup utility
|
/// @ingroup utility
|
||||||
///
|
///
|
||||||
|
|
||||||
|
#include <cstdlib>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#include <stdlib.h> // size_t
|
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class FFT
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class FFT {
|
class FFT {
|
||||||
private:
|
|
||||||
void DoTransform(size_t n_samples,float *input,float *output_r,float *output_i,bool inverse);
|
void DoTransform(size_t n_samples,float *input,float *output_r,float *output_i,bool inverse);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -60,11 +60,6 @@ class VideoZoomSlider;
|
||||||
|
|
||||||
namespace agi { struct Context; class OptionValue; }
|
namespace agi { struct Context; class OptionValue; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class FrameMain
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class FrameMain: public wxFrame {
|
class FrameMain: public wxFrame {
|
||||||
friend class AegisubFileDropTarget;
|
friend class AegisubFileDropTarget;
|
||||||
|
|
||||||
|
|
|
@ -360,7 +360,6 @@ void OpenGLTextGlyph::Draw(float x, float y) const {
|
||||||
glDisableClientState(GL_TEXTURE_COORD_ARRAY);
|
glDisableClientState(GL_TEXTURE_COORD_ARRAY);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
OpenGLTextGlyph::OpenGLTextGlyph(int value, wxFont const& font)
|
OpenGLTextGlyph::OpenGLTextGlyph(int value, wxFont const& font)
|
||||||
: str(wxChar(value))
|
: str(wxChar(value))
|
||||||
, tex(0)
|
, tex(0)
|
||||||
|
|
|
@ -43,47 +43,20 @@
|
||||||
struct OpenGLTextGlyph;
|
struct OpenGLTextGlyph;
|
||||||
class OpenGLTextTexture;
|
class OpenGLTextTexture;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
typedef boost::container::map<int,OpenGLTextGlyph> glyphMap;
|
typedef boost::container::map<int,OpenGLTextGlyph> glyphMap;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class OpenGLText
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class OpenGLText {
|
class OpenGLText {
|
||||||
/// DOCME
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
float r,g,b,a;
|
float r,g,b,a;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int lineHeight;
|
int lineHeight;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int fontSize;
|
int fontSize;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool fontBold;
|
bool fontBold;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool fontItalics;
|
bool fontItalics;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxString fontFace;
|
wxString fontFace;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxFont font;
|
wxFont font;
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
glyphMap glyphs;
|
glyphMap glyphs;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
std::vector<std::shared_ptr<OpenGLTextTexture> > textures;
|
std::vector<std::shared_ptr<OpenGLTextTexture> > textures;
|
||||||
|
|
||||||
OpenGLText(OpenGLText const&);
|
OpenGLText(OpenGLText const&);
|
||||||
|
|
|
@ -25,11 +25,6 @@
|
||||||
|
|
||||||
class wxColour;
|
class wxColour;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class OpenGLWrapper
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class OpenGLWrapper {
|
class OpenGLWrapper {
|
||||||
float line_r, line_g, line_b, line_a;
|
float line_r, line_g, line_b, line_a;
|
||||||
float fill_r, fill_g, fill_b, fill_a;
|
float fill_r, fill_g, fill_b, fill_a;
|
||||||
|
|
|
@ -32,14 +32,8 @@
|
||||||
/// @ingroup custom_control
|
/// @ingroup custom_control
|
||||||
///
|
///
|
||||||
|
|
||||||
|
|
||||||
#include <wx/button.h>
|
#include <wx/button.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class HelpButton
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class HelpButton : public wxButton {
|
class HelpButton : public wxButton {
|
||||||
public:
|
public:
|
||||||
HelpButton(wxWindow *parent, wxString const& page="", wxPoint position=wxDefaultPosition, wxSize size=wxDefaultSize);
|
HelpButton(wxWindow *parent, wxString const& page="", wxPoint position=wxDefaultPosition, wxSize size=wxDefaultSize);
|
||||||
|
|
|
@ -38,13 +38,8 @@
|
||||||
|
|
||||||
class AudioProvider;
|
class AudioProvider;
|
||||||
|
|
||||||
/// @class AudioPlayer
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AudioPlayer {
|
class AudioPlayer {
|
||||||
protected:
|
protected:
|
||||||
/// DOCME
|
|
||||||
AudioProvider *provider;
|
AudioProvider *provider;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -39,28 +39,15 @@
|
||||||
#include <libaegisub/exception.h>
|
#include <libaegisub/exception.h>
|
||||||
#include "factory_manager.h"
|
#include "factory_manager.h"
|
||||||
|
|
||||||
/// @class AudioProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AudioProvider {
|
class AudioProvider {
|
||||||
protected:
|
protected:
|
||||||
/// DOCME
|
|
||||||
int channels;
|
int channels;
|
||||||
|
|
||||||
/// for one channel, ie. number of PCM frames
|
/// for one channel, ie. number of PCM frames
|
||||||
int64_t num_samples;
|
int64_t num_samples;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int sample_rate;
|
int sample_rate;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int bytes_per_sample;
|
int bytes_per_sample;
|
||||||
|
|
||||||
bool float_samples;
|
bool float_samples;
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
wxString filename;
|
wxString filename;
|
||||||
|
|
||||||
virtual void FillBuffer(void *buf, int64_t start, int64_t count) const = 0;
|
virtual void FillBuffer(void *buf, int64_t start, int64_t count) const = 0;
|
||||||
|
@ -85,11 +72,6 @@ public:
|
||||||
virtual bool NeedsCache() const { return false; }
|
virtual bool NeedsCache() const { return false; }
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AudioProviderFactory
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AudioProviderFactory : public Factory1<AudioProvider, wxString> {
|
class AudioProviderFactory : public Factory1<AudioProvider, wxString> {
|
||||||
public:
|
public:
|
||||||
static void RegisterProviders();
|
static void RegisterProviders();
|
||||||
|
|
|
@ -39,28 +39,14 @@
|
||||||
class AssFile;
|
class AssFile;
|
||||||
class AegiVideoFrame;
|
class AegiVideoFrame;
|
||||||
|
|
||||||
/// @class SubtitlesProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SubtitlesProvider {
|
class SubtitlesProvider {
|
||||||
public:
|
public:
|
||||||
virtual ~SubtitlesProvider() { };
|
virtual ~SubtitlesProvider() { };
|
||||||
|
|
||||||
virtual void LoadSubtitles(AssFile *subs)=0;
|
virtual void LoadSubtitles(AssFile *subs)=0;
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param dst
|
|
||||||
/// @param time
|
|
||||||
///
|
|
||||||
virtual void DrawSubtitles(AegiVideoFrame &dst,double time)=0;
|
virtual void DrawSubtitles(AegiVideoFrame &dst,double time)=0;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SubtitlesProviderFactoryManager
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SubtitlesProviderFactory : public Factory1<SubtitlesProvider, std::string> {
|
class SubtitlesProviderFactory : public Factory1<SubtitlesProvider, std::string> {
|
||||||
public:
|
public:
|
||||||
static SubtitlesProvider *GetProvider();
|
static SubtitlesProvider *GetProvider();
|
||||||
|
|
|
@ -41,15 +41,11 @@
|
||||||
|
|
||||||
class AegiVideoFrame;
|
class AegiVideoFrame;
|
||||||
|
|
||||||
/// @class VideoProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class VideoProvider {
|
class VideoProvider {
|
||||||
public:
|
public:
|
||||||
virtual ~VideoProvider() {}
|
virtual ~VideoProvider() {}
|
||||||
|
|
||||||
// Override this method to actually get frames
|
/// Override this method to actually get frames
|
||||||
virtual const AegiVideoFrame GetFrame(int n)=0;
|
virtual const AegiVideoFrame GetFrame(int n)=0;
|
||||||
|
|
||||||
// Override the following methods to get video information:
|
// Override the following methods to get video information:
|
||||||
|
|
|
@ -95,7 +95,6 @@ static const char *LastStartupState = nullptr;
|
||||||
|
|
||||||
#ifdef __VISUALC__
|
#ifdef __VISUALC__
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
#define MS_VC_EXCEPTION 0x406d1388
|
#define MS_VC_EXCEPTION 0x406d1388
|
||||||
|
|
||||||
/// Parameters for setting the thread name
|
/// Parameters for setting the thread name
|
||||||
|
|
|
@ -41,11 +41,6 @@ DEFINE_SIMPLE_EXCEPTION_NOINNER(MatroskaException, agi::Exception, "matroksa_wra
|
||||||
|
|
||||||
class AssFile;
|
class AssFile;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class MatroskaWrapper
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class MatroskaWrapper {
|
class MatroskaWrapper {
|
||||||
public:
|
public:
|
||||||
/// Check if the file is a matroska file with at least one subtitle track
|
/// Check if the file is a matroska file with at least one subtitle track
|
||||||
|
|
|
@ -47,11 +47,7 @@
|
||||||
|
|
||||||
PluginManager::PluginManager() {
|
PluginManager::PluginManager() {
|
||||||
init = false;
|
init = false;
|
||||||
|
|
||||||
#ifdef WITH_AUTO4_LUA
|
|
||||||
lua = nullptr;
|
lua = nullptr;
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
PluginManager::~PluginManager() {
|
PluginManager::~PluginManager() {
|
||||||
|
|
|
@ -34,20 +34,9 @@
|
||||||
|
|
||||||
namespace Automation4 { class ScriptFactory; }
|
namespace Automation4 { class ScriptFactory; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class PluginManager
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class PluginManager {
|
class PluginManager {
|
||||||
private:
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
bool init;
|
bool init;
|
||||||
|
|
||||||
#ifdef WITH_AUTO4_LUA
|
|
||||||
Automation4::ScriptFactory *lua;
|
Automation4::ScriptFactory *lua;
|
||||||
#endif
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PluginManager();
|
PluginManager();
|
||||||
|
@ -55,5 +44,3 @@ public:
|
||||||
|
|
||||||
void RegisterBuiltInPlugins();
|
void RegisterBuiltInPlugins();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class ScintillaTextCtrl
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class ScintillaTextCtrl : public wxStyledTextCtrl {
|
class ScintillaTextCtrl : public wxStyledTextCtrl {
|
||||||
wxString text;
|
wxString text;
|
||||||
|
|
||||||
|
|
|
@ -41,9 +41,6 @@
|
||||||
|
|
||||||
class VisualToolBase;
|
class VisualToolBase;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class Spline
|
|
||||||
/// @brief DOCME
|
|
||||||
class Spline : private std::list<SplineCurve> {
|
class Spline : private std::list<SplineCurve> {
|
||||||
/// Visual tool to do the conversion between script and video pixels
|
/// Visual tool to do the conversion between script and video pixels
|
||||||
const VisualToolBase &coord_translator;
|
const VisualToolBase &coord_translator;
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SplineCurve
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SplineCurve {
|
class SplineCurve {
|
||||||
/// Closest t in segment p1-p2 to point p3
|
/// Closest t in segment p1-p2 to point p3
|
||||||
float GetClosestSegmentPart(Vector2D p1, Vector2D p2, Vector2D p3) const;
|
float GetClosestSegmentPart(Vector2D p1, Vector2D p2, Vector2D p3) const;
|
||||||
|
@ -59,7 +54,6 @@ public:
|
||||||
Vector2D p3;
|
Vector2D p3;
|
||||||
Vector2D p4;
|
Vector2D p4;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
CurveType type;
|
CurveType type;
|
||||||
|
|
||||||
SplineCurve(Vector2D p1 = Vector2D(0, 0));
|
SplineCurve(Vector2D p1 = Vector2D(0, 0));
|
||||||
|
|
|
@ -34,11 +34,11 @@
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
|
#include "standard_paths.h"
|
||||||
|
|
||||||
#include <wx/filename.h>
|
#include <wx/filename.h>
|
||||||
#include <wx/stdpaths.h>
|
#include <wx/stdpaths.h>
|
||||||
|
|
||||||
#include "standard_paths.h"
|
|
||||||
|
|
||||||
StandardPaths &StandardPaths::GetInstance() {
|
StandardPaths &StandardPaths::GetInstance() {
|
||||||
static StandardPaths instance;
|
static StandardPaths instance;
|
||||||
return instance;
|
return instance;
|
||||||
|
|
|
@ -33,18 +33,12 @@
|
||||||
///
|
///
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
#include <wx/string.h>
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class StandardPaths
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class StandardPaths {
|
class StandardPaths {
|
||||||
static StandardPaths &GetInstance();
|
static StandardPaths &GetInstance();
|
||||||
|
|
||||||
/// DOCME
|
std::map<wxString, wxString> paths;
|
||||||
std::map<wxString,wxString> paths;
|
|
||||||
|
|
||||||
StandardPaths();
|
StandardPaths();
|
||||||
StandardPaths(StandardPaths const&);
|
StandardPaths(StandardPaths const&);
|
||||||
|
|
|
@ -39,10 +39,6 @@
|
||||||
|
|
||||||
#include "string_codec.h"
|
#include "string_codec.h"
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param input
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
wxString inline_string_encode(const wxString &input)
|
wxString inline_string_encode(const wxString &input)
|
||||||
{
|
{
|
||||||
const size_t inlen = input.length();
|
const size_t inlen = input.length();
|
||||||
|
@ -59,10 +55,6 @@ wxString inline_string_encode(const wxString &input)
|
||||||
return output;
|
return output;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param input
|
|
||||||
///
|
|
||||||
wxString inline_string_decode(const wxString &input)
|
wxString inline_string_decode(const wxString &input)
|
||||||
{
|
{
|
||||||
const size_t inlen = input.length();
|
const size_t inlen = input.length();
|
||||||
|
@ -86,5 +78,3 @@ wxString inline_string_decode(const wxString &input)
|
||||||
}
|
}
|
||||||
return output;
|
return output;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -52,7 +52,6 @@
|
||||||
///
|
///
|
||||||
/// The encoded string should be usable in any kind of field in an ASS file.
|
/// The encoded string should be usable in any kind of field in an ASS file.
|
||||||
|
|
||||||
|
|
||||||
#include <wx/string.h>
|
#include <wx/string.h>
|
||||||
|
|
||||||
wxString inline_string_encode(const wxString &input);
|
wxString inline_string_encode(const wxString &input);
|
||||||
|
|
|
@ -64,8 +64,6 @@ class wxTextCtrl;
|
||||||
|
|
||||||
template<class Base> class Placeholder;
|
template<class Base> class Placeholder;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SubsEditBox
|
|
||||||
/// @brief Main subtitle edit box
|
/// @brief Main subtitle edit box
|
||||||
///
|
///
|
||||||
/// Controls the text edit and all surrounding controls
|
/// Controls the text edit and all surrounding controls
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SubtitlesGrid
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SubtitlesGrid: public BaseGrid {
|
class SubtitlesGrid: public BaseGrid {
|
||||||
public:
|
public:
|
||||||
SubtitlesGrid(wxWindow *parent, agi::Context *context);
|
SubtitlesGrid(wxWindow *parent, agi::Context *context);
|
||||||
|
|
|
@ -42,9 +42,7 @@ class AssStyle;
|
||||||
class SubtitlesProvider;
|
class SubtitlesProvider;
|
||||||
class VideoProvider;
|
class VideoProvider;
|
||||||
|
|
||||||
/// DOCME
|
/// Preview window to show a short string with a given ass style
|
||||||
/// @class SubtitlesPreview
|
|
||||||
/// @brief Preview window to show a short string with a given ass style
|
|
||||||
class SubtitlesPreview : public wxWindow {
|
class SubtitlesPreview : public wxWindow {
|
||||||
/// The subtitle provider used to render the string
|
/// The subtitle provider used to render the string
|
||||||
agi::scoped_ptr<SubtitlesProvider> provider;
|
agi::scoped_ptr<SubtitlesProvider> provider;
|
||||||
|
|
|
@ -45,11 +45,6 @@ class AssEntry;
|
||||||
class AssFile;
|
class AssFile;
|
||||||
namespace agi { namespace vfr { class Framerate; } }
|
namespace agi { namespace vfr { class Framerate; } }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SubtitleFormat {
|
class SubtitleFormat {
|
||||||
wxString name;
|
wxString name;
|
||||||
|
|
||||||
|
|
|
@ -34,11 +34,6 @@
|
||||||
|
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class ASSSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AssSubtitleFormat : public SubtitleFormat {
|
class AssSubtitleFormat : public SubtitleFormat {
|
||||||
public:
|
public:
|
||||||
AssSubtitleFormat();
|
AssSubtitleFormat();
|
||||||
|
|
|
@ -34,12 +34,6 @@
|
||||||
|
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class EncoreSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class EncoreSubtitleFormat : public SubtitleFormat {
|
class EncoreSubtitleFormat : public SubtitleFormat {
|
||||||
public:
|
public:
|
||||||
EncoreSubtitleFormat();
|
EncoreSubtitleFormat();
|
||||||
|
|
|
@ -34,11 +34,6 @@
|
||||||
|
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class MicroDVDSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class MicroDVDSubtitleFormat : public SubtitleFormat {
|
class MicroDVDSubtitleFormat : public SubtitleFormat {
|
||||||
public:
|
public:
|
||||||
MicroDVDSubtitleFormat();
|
MicroDVDSubtitleFormat();
|
||||||
|
|
|
@ -34,11 +34,6 @@
|
||||||
|
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class MKVSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class MKVSubtitleFormat : public SubtitleFormat {
|
class MKVSubtitleFormat : public SubtitleFormat {
|
||||||
public:
|
public:
|
||||||
MKVSubtitleFormat();
|
MKVSubtitleFormat();
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
class AssDialogue;
|
class AssDialogue;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class SRTSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class SRTSubtitleFormat : public SubtitleFormat {
|
class SRTSubtitleFormat : public SubtitleFormat {
|
||||||
wxString ConvertTags(const AssDialogue *diag) const;
|
wxString ConvertTags(const AssDialogue *diag) const;
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -37,11 +37,6 @@
|
||||||
class AssDialogue;
|
class AssDialogue;
|
||||||
class SmpteFormatter;
|
class SmpteFormatter;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class TranStationSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class TranStationSubtitleFormat : public SubtitleFormat {
|
class TranStationSubtitleFormat : public SubtitleFormat {
|
||||||
wxString ConvertLine(AssFile *file, AssDialogue *line, agi::vfr::Framerate const& fps, SmpteFormatter const& ft, int nextl_start) const;
|
wxString ConvertLine(AssFile *file, AssDialogue *line, agi::vfr::Framerate const& fps, SmpteFormatter const& ft, int nextl_start) const;
|
||||||
|
|
||||||
|
|
|
@ -37,11 +37,6 @@
|
||||||
class AssDialogue;
|
class AssDialogue;
|
||||||
class wxXmlNode;
|
class wxXmlNode;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class TTXTSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class TTXTSubtitleFormat : public SubtitleFormat {
|
class TTXTSubtitleFormat : public SubtitleFormat {
|
||||||
AssDialogue *ProcessLine(wxXmlNode *node, AssDialogue *prev, int version) const;
|
AssDialogue *ProcessLine(wxXmlNode *node, AssDialogue *prev, int version) const;
|
||||||
void ProcessHeader(wxXmlNode *node) const;
|
void ProcessHeader(wxXmlNode *node) const;
|
||||||
|
|
|
@ -34,11 +34,6 @@
|
||||||
|
|
||||||
#include "subtitle_format.h"
|
#include "subtitle_format.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class TXTSubtitleFormat
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class TXTSubtitleFormat : public SubtitleFormat {
|
class TXTSubtitleFormat : public SubtitleFormat {
|
||||||
public:
|
public:
|
||||||
TXTSubtitleFormat();
|
TXTSubtitleFormat();
|
||||||
|
|
|
@ -43,11 +43,6 @@
|
||||||
typedef void csri_rend;
|
typedef void csri_rend;
|
||||||
typedef void csri_inst;
|
typedef void csri_inst;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class CSRISubtitlesProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class CSRISubtitlesProvider : public SubtitlesProvider {
|
class CSRISubtitlesProvider : public SubtitlesProvider {
|
||||||
agi::scoped_holder<csri_inst*> instance;
|
agi::scoped_holder<csri_inst*> instance;
|
||||||
csri_rend *renderer;
|
csri_rend *renderer;
|
||||||
|
|
|
@ -56,9 +56,6 @@
|
||||||
#include "video_context.h"
|
#include "video_context.h"
|
||||||
#include "video_frame.h"
|
#include "video_frame.h"
|
||||||
|
|
||||||
|
|
||||||
/// @brief Handle libass messages
|
|
||||||
///
|
|
||||||
static void msg_callback(int level, const char *fmt, va_list args, void *) {
|
static void msg_callback(int level, const char *fmt, va_list args, void *) {
|
||||||
if (level >= 7) return;
|
if (level >= 7) return;
|
||||||
char buf[1024];
|
char buf[1024];
|
||||||
|
@ -135,16 +132,11 @@ LibassSubtitlesProvider::LibassSubtitlesProvider(std::string) {
|
||||||
wait_for_cache_thread(&cache_worker);
|
wait_for_cache_thread(&cache_worker);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief Destructor
|
|
||||||
///
|
|
||||||
LibassSubtitlesProvider::~LibassSubtitlesProvider() {
|
LibassSubtitlesProvider::~LibassSubtitlesProvider() {
|
||||||
if (ass_track) ass_free_track(ass_track);
|
if (ass_track) ass_free_track(ass_track);
|
||||||
if (ass_renderer) ass_renderer_done(ass_renderer);
|
if (ass_renderer) ass_renderer_done(ass_renderer);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief Load subtitles
|
|
||||||
/// @param subs
|
|
||||||
///
|
|
||||||
void LibassSubtitlesProvider::LoadSubtitles(AssFile *subs) {
|
void LibassSubtitlesProvider::LoadSubtitles(AssFile *subs) {
|
||||||
// Prepare subtitles
|
// Prepare subtitles
|
||||||
std::vector<char> data;
|
std::vector<char> data;
|
||||||
|
@ -156,24 +148,11 @@ void LibassSubtitlesProvider::LoadSubtitles(AssFile *subs) {
|
||||||
if (!ass_track) throw "libass failed to load subtitles.";
|
if (!ass_track) throw "libass failed to load subtitles.";
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
#define _r(c) ((c)>>24)
|
#define _r(c) ((c)>>24)
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
#define _g(c) (((c)>>16)&0xFF)
|
#define _g(c) (((c)>>16)&0xFF)
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
#define _b(c) (((c)>>8)&0xFF)
|
#define _b(c) (((c)>>8)&0xFF)
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
#define _a(c) ((c)&0xFF)
|
#define _a(c) ((c)&0xFF)
|
||||||
|
|
||||||
|
|
||||||
/// @brief Draw subtitles
|
|
||||||
/// @param frame
|
|
||||||
/// @param time
|
|
||||||
/// @return
|
|
||||||
///
|
|
||||||
void LibassSubtitlesProvider::DrawSubtitles(AegiVideoFrame &frame,double time) {
|
void LibassSubtitlesProvider::DrawSubtitles(AegiVideoFrame &frame,double time) {
|
||||||
// Set size
|
// Set size
|
||||||
ass_set_frame_size(ass_renderer, frame.w, frame.h);
|
ass_set_frame_size(ass_renderer, frame.w, frame.h);
|
||||||
|
@ -238,7 +217,6 @@ void LibassSubtitlesProvider::CacheFonts() {
|
||||||
new FontConfigCacheThread(ass_library, &cache_worker);
|
new FontConfigCacheThread(ass_library, &cache_worker);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ASS_Library* LibassSubtitlesProvider::ass_library;
|
ASS_Library* LibassSubtitlesProvider::ass_library;
|
||||||
FontConfigCacheThread* LibassSubtitlesProvider::cache_worker = nullptr;
|
FontConfigCacheThread* LibassSubtitlesProvider::cache_worker = nullptr;
|
||||||
|
|
||||||
|
|
|
@ -45,19 +45,9 @@ extern "C" {
|
||||||
|
|
||||||
class FontConfigCacheThread;
|
class FontConfigCacheThread;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class LibassSubtitlesProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class LibassSubtitlesProvider : public SubtitlesProvider {
|
class LibassSubtitlesProvider : public SubtitlesProvider {
|
||||||
/// DOCME
|
|
||||||
static ASS_Library* ass_library;
|
static ASS_Library* ass_library;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ASS_Renderer* ass_renderer;
|
ASS_Renderer* ass_renderer;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
ASS_Track* ass_track;
|
ASS_Track* ass_track;
|
||||||
|
|
||||||
static FontConfigCacheThread *cache_worker;
|
static FontConfigCacheThread *cache_worker;
|
||||||
|
|
|
@ -43,11 +43,6 @@
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
#include "text_file_writer.h"
|
#include "text_file_writer.h"
|
||||||
|
|
||||||
|
|
||||||
/// @brief DOCME
|
|
||||||
/// @param filename
|
|
||||||
/// @param encoding
|
|
||||||
///
|
|
||||||
TextFileWriter::TextFileWriter(wxString const& filename, wxString encoding)
|
TextFileWriter::TextFileWriter(wxString const& filename, wxString encoding)
|
||||||
: file(new agi::io::Save(STD_STR(filename), true))
|
: file(new agi::io::Save(STD_STR(filename), true))
|
||||||
, conv()
|
, conv()
|
||||||
|
|
|
@ -39,27 +39,14 @@
|
||||||
#include <wx/string.h>
|
#include <wx/string.h>
|
||||||
|
|
||||||
namespace agi {
|
namespace agi {
|
||||||
namespace charset {
|
namespace charset { class IconvWrapper; }
|
||||||
class IconvWrapper;
|
namespace io { class Save; }
|
||||||
}
|
|
||||||
namespace io {
|
|
||||||
class Save;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#include <libaegisub/scoped_ptr.h>
|
#include <libaegisub/scoped_ptr.h>
|
||||||
|
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class TextFileWriter
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class TextFileWriter {
|
class TextFileWriter {
|
||||||
/// DOCME
|
|
||||||
agi::scoped_ptr<agi::io::Save> file;
|
agi::scoped_ptr<agi::io::Save> file;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
agi::scoped_ptr<agi::charset::IconvWrapper> conv;
|
agi::scoped_ptr<agi::charset::IconvWrapper> conv;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -38,11 +38,6 @@
|
||||||
namespace agi { struct Context; }
|
namespace agi { struct Context; }
|
||||||
namespace cmd { class Command; }
|
namespace cmd { class Command; }
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class ToggleBitmap
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class ToggleBitmap : public wxControl {
|
class ToggleBitmap : public wxControl {
|
||||||
agi::Context *context;
|
agi::Context *context;
|
||||||
cmd::Command &command;
|
cmd::Command &command;
|
||||||
|
|
|
@ -39,11 +39,6 @@ struct ToolTipBinding;
|
||||||
class wxString;
|
class wxString;
|
||||||
class wxWindow;
|
class wxWindow;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class ToolTipManager
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class ToolTipManager {
|
class ToolTipManager {
|
||||||
ToolTipManager();
|
ToolTipManager();
|
||||||
~ToolTipManager();
|
~ToolTipManager();
|
||||||
|
|
|
@ -34,12 +34,7 @@
|
||||||
|
|
||||||
#include <wx/validate.h>
|
#include <wx/validate.h>
|
||||||
|
|
||||||
|
/// A wx validator that only allows valid numbers
|
||||||
/// DOCME
|
|
||||||
/// @class NumValidator
|
|
||||||
/// @brief wx validator that only allows valid numbers
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class NumValidator : public wxValidator {
|
class NumValidator : public wxValidator {
|
||||||
double fValue; ///< Value if isFloat is true
|
double fValue; ///< Value if isFloat is true
|
||||||
int iValue; ///< Value if isFloat is false
|
int iValue; ///< Value if isFloat is false
|
||||||
|
|
|
@ -25,11 +25,6 @@
|
||||||
|
|
||||||
#include <wx/gdicmn.h>
|
#include <wx/gdicmn.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class Vector2D
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class Vector2D {
|
class Vector2D {
|
||||||
float x, y;
|
float x, y;
|
||||||
|
|
||||||
|
|
|
@ -60,8 +60,6 @@ namespace agi {
|
||||||
class OptionValue;
|
class OptionValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @class VideoDisplay
|
|
||||||
/// @brief DOCME
|
|
||||||
class VideoDisplay : public wxGLCanvas {
|
class VideoDisplay : public wxGLCanvas {
|
||||||
/// Signals the display is connected to
|
/// Signals the display is connected to
|
||||||
std::deque<agi::signal::Connection> slots;
|
std::deque<agi::signal::Connection> slots;
|
||||||
|
|
|
@ -36,11 +36,6 @@
|
||||||
|
|
||||||
#include <wx/image.h>
|
#include <wx/image.h>
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AegiVideoFrame
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AegiVideoFrame {
|
class AegiVideoFrame {
|
||||||
/// Whether the object owns its buffer. If this is false, **data should never be modified
|
/// Whether the object owns its buffer. If this is false, **data should never be modified
|
||||||
bool ownMem;
|
bool ownMem;
|
||||||
|
|
|
@ -38,11 +38,6 @@
|
||||||
#include "include/aegisub/video_provider.h"
|
#include "include/aegisub/video_provider.h"
|
||||||
#include "video_frame.h"
|
#include "video_frame.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class AvisynthVideoProvider
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class AvisynthVideoProvider: public VideoProvider {
|
class AvisynthVideoProvider: public VideoProvider {
|
||||||
AviSynthWrapper avs;
|
AviSynthWrapper avs;
|
||||||
AegiVideoFrame iframe;
|
AegiVideoFrame iframe;
|
||||||
|
|
|
@ -154,9 +154,7 @@ public:
|
||||||
virtual ~VisualToolBase();
|
virtual ~VisualToolBase();
|
||||||
};
|
};
|
||||||
|
|
||||||
/// @class VisualTool
|
/// Visual tool base class containing all common feature-related functionality
|
||||||
/// @brief Visual tool base class containing all common feature-related functionality
|
|
||||||
/// DOCME
|
|
||||||
template<class FeatureType>
|
template<class FeatureType>
|
||||||
class VisualTool : public VisualToolBase {
|
class VisualTool : public VisualToolBase {
|
||||||
protected:
|
protected:
|
||||||
|
|
|
@ -22,19 +22,13 @@
|
||||||
#include "visual_feature.h"
|
#include "visual_feature.h"
|
||||||
#include "visual_tool.h"
|
#include "visual_tool.h"
|
||||||
|
|
||||||
/// @class ClipCorner
|
/// VisualDraggableFeature with siblings
|
||||||
/// @brief VisualDraggableFeature with siblings
|
|
||||||
struct ClipCorner : public VisualDraggableFeature {
|
struct ClipCorner : public VisualDraggableFeature {
|
||||||
ClipCorner *horiz; /// Other corner on this corner's horizontal line
|
ClipCorner *horiz; ///< Other corner on this corner's horizontal line
|
||||||
ClipCorner *vert; /// Other corner on this corner's vertical line
|
ClipCorner *vert; ///< Other corner on this corner's vertical line
|
||||||
ClipCorner() : VisualDraggableFeature() , horiz(0) , vert(0) { }
|
ClipCorner() : VisualDraggableFeature() , horiz(0) , vert(0) { }
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class VisualToolClip
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class VisualToolClip : public VisualTool<ClipCorner> {
|
class VisualToolClip : public VisualTool<ClipCorner> {
|
||||||
Vector2D cur_1;
|
Vector2D cur_1;
|
||||||
Vector2D cur_2;
|
Vector2D cur_2;
|
||||||
|
|
|
@ -22,9 +22,6 @@
|
||||||
#include "visual_feature.h"
|
#include "visual_feature.h"
|
||||||
#include "visual_tool.h"
|
#include "visual_tool.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class VisualToolRotateXY
|
|
||||||
/// @brief DOCME
|
|
||||||
class VisualToolRotateXY : public VisualTool<VisualDraggableFeature> {
|
class VisualToolRotateXY : public VisualTool<VisualDraggableFeature> {
|
||||||
float angle_x; /// Current x rotation
|
float angle_x; /// Current x rotation
|
||||||
float angle_y; /// Current y rotation
|
float angle_y; /// Current y rotation
|
||||||
|
|
|
@ -22,11 +22,6 @@
|
||||||
#include "visual_feature.h"
|
#include "visual_feature.h"
|
||||||
#include "visual_tool.h"
|
#include "visual_tool.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class VisualToolRotateZ
|
|
||||||
/// @brief DOCME
|
|
||||||
///
|
|
||||||
/// DOCME
|
|
||||||
class VisualToolRotateZ : public VisualTool<VisualDraggableFeature> {
|
class VisualToolRotateZ : public VisualTool<VisualDraggableFeature> {
|
||||||
float angle; ///< Current Z rotation
|
float angle; ///< Current Z rotation
|
||||||
float orig_angle; ///< Z rotation at the beginning of the current hold
|
float orig_angle; ///< Z rotation at the beginning of the current hold
|
||||||
|
|
|
@ -22,9 +22,6 @@
|
||||||
#include "visual_feature.h"
|
#include "visual_feature.h"
|
||||||
#include "visual_tool.h"
|
#include "visual_tool.h"
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class VisualToolScale
|
|
||||||
/// @brief DOCME
|
|
||||||
class VisualToolScale : public VisualTool<VisualDraggableFeature> {
|
class VisualToolScale : public VisualTool<VisualDraggableFeature> {
|
||||||
Vector2D scale; ///< The current scale
|
Vector2D scale; ///< The current scale
|
||||||
Vector2D initial_scale; ///< The scale at the beginning of the current hold
|
Vector2D initial_scale; ///< The scale at the beginning of the current hold
|
||||||
|
|
|
@ -40,9 +40,6 @@ struct VisualToolVectorClipDraggableFeature : public VisualDraggableFeature {
|
||||||
{ }
|
{ }
|
||||||
};
|
};
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
/// @class VisualToolVectorClip
|
|
||||||
/// @brief DOCME
|
|
||||||
class VisualToolVectorClip : public VisualTool<VisualToolVectorClipDraggableFeature> {
|
class VisualToolVectorClip : public VisualTool<VisualToolVectorClipDraggableFeature> {
|
||||||
Spline spline; /// The current spline
|
Spline spline; /// The current spline
|
||||||
wxToolBar *toolBar; /// The subtoolbar
|
wxToolBar *toolBar; /// The subtoolbar
|
||||||
|
|
Loading…
Reference in New Issue