|
MythTV master
|
#include <unistd.h>#include <stdbool.h>#include <stdio.h>#include <stdlib.h>#include <stdarg.h>#include <stddef.h>#include <string.h>#include <sys/types.h>#include <sys/stat.h>#include <time.h>#include <errno.h>#include <ctype.h>#include <setjmp.h>#include <zlib.h>#include <stdint.h>Go to the source code of this file.
Classes | |
| struct | exc__state |
| struct | Png4File |
| struct | BoundStr |
Macros | |
| #define | GCCATTR_PRINTF(m, n) __attribute__ ((format (printf, m, n))) |
| #define | GCCATTR_UNUSED __attribute ((unused)) |
| #define | GCCATTR_NORETURN __attribute ((noreturn)) |
| #define | GCCATTR_CONST __attribute ((const)) |
| #define | CUS (const unsigned char *) |
| #define | exc_try(x) |
| #define | exc_ftry(x) |
| #define | exc_catch(x, t) else if ((t) == exc_type##x) |
| #define | exc_end(x) else __exc_throw(exc_type##x); EXC.m_last = exc_s##x.m_prev; } while (0) |
| #define | exc_return(x) for (EXC.m_last = exc_p##x;) return |
| #define | exc_fthrow(x) for (EXC.m_last = exc_p##x;) ex_throw |
| #define | exc_catchall else |
| #define | exc_endall(x) EXC.m_last = exc_s##x.m_prev; } while (0) |
| #define | exc_cleanup() EXC.m_last = NULL; |
| #define | xxfwriteCS(f, s) xxfwrite(f, CUS s, sizeof (s) - 1) |
Typedefs | |
| typedef int8_t | ei8 |
| typedef uint8_t | eu8 |
| typedef int16_t | ei16 |
| typedef uint16_t | eu16 |
| typedef int32_t | ei32 |
| typedef uint32_t | eu32 |
| typedef int_least8_t | li8 |
| typedef uint_least8_t | lu8 |
| typedef int_least16_t | li16 |
| typedef uint_least16_t | lu16 |
| typedef int_least32_t | li32 |
| typedef uint_least32_t | lu32 |
| typedef int_fast8_t | fi8 |
| typedef uint_fast8_t | fu8 |
| typedef int_fast16_t | fi16 |
| typedef uint_fast16_t | fu16 |
| typedef int_fast32_t | fi32 |
| typedef uint_fast32_t | fu32 |
| typedef struct Png4File | Png4File |
| typedef struct BoundStr | BoundStr |
Enumerations | |
| enum | { MiscError = 1 , EOFIndicator , IndexError } |
Functions | |
| int | sup2dast (const char *supfile, const char *ifofile, int delay_ms) |
| static GCCATTR_NORETURN void | __exc_throw (int type) |
| static GCCATTR_NORETURN void | exc_throw (int type, const char *format,...) |
| static eu8 * | xxfread (FILE *stream, eu8 *ptr, size_t size) |
| static void | xxfwrite (FILE *stream, const eu8 *ptr, size_t size) |
| static eu8 | clamp (eu8 value, eu8 low, eu8 high) |
| static void | yuv2rgb (int y, int cr, int cb, eu8 *r, eu8 *g, eu8 *b) |
| static void | rgb2yuv (eu8 r, eu8 g, eu8 b, eu8 *y, eu8 *cr, eu8 *cb) |
| static FILE * | xfopen (const char *filename, const char *mode) |
| static void | xfseek0 (FILE *stream, long offset) |
| static void | xmkdir (const char *path, int mode) |
| static bool | fexists (const char *filename) |
| static bool | dexists (const char *filename) |
| static fu32 | get_uint32_be (const eu8 *bytes) |
| static fu16 | get_uint16_be (const eu8 *bytes) |
| static fu32 | get_uint32_le (const eu8 *bytes) |
| static void | set_uint32_be (eu8 *ptr, eu32 value) |
| static void | set_uint16_le (eu8 *ptr, eu16 value) |
| static void | xxfwrite_uint32_be (FILE *fh, eu32 value) |
| static void | ifopalette (const char *filename, eu8 yuvpalette[16][3], eu8 rgbpalette[16][3]) |
| static void | set2palettes (int value, eu8 *yuvpalpart, eu8 *rgbpalpart) |
| static void | argpalette (const char *arg, eu8 yuvpalette[16][3], eu8 rgbpalette[16][3]) |
| static void | png4file_init (Png4File *self, eu8 palette[4][3]) |
| static void | png4file_open (Png4File *self, const char *filename, int height, int width) |
| static void | png4file_flush (Png4File *self) |
| static void | png4file_addpixel (Png4File *self, eu8 pixel) |
| static void | png4file_endrow (Png4File *self) |
| static void | png4file_close (Png4File *self) |
| static eu8 | getnibble (eu8 **data, int *nibble) |
| static void | getpixelline (eu8 **data, int width, Png4File *picfile) |
| static void | makebitmap (eu8 *data, int w, int h, int top, int bot, char *filename, eu8 palette[4][3]) |
| static char * | pts2ts (fu32 pts, char *rvbuf, bool is_png_filename) |
| static void | boundstr_init (BoundStr *bs, eu8 *p, int l) |
| static eu8 * | boundstr_read (BoundStr *bs, int l) |
| static void | pxsubtitle (const char *supfile, FILE *ofh, eu8 palette[16][3], bool createpics, int delay_ms, char *fnbuf, char *fnbuf_fp) |
| static bool | samepalette (char *filename, eu8 palette[16][3]) |
Variables | |
| struct { | |
| struct exc__state * m_last | |
| char m_msgbuf [1024] | |
| int m_buflen | |
| } | EXC |
| #define CUS (const unsigned char *) |
Definition at line 72 of file pxsup2dast.c.
| #define exc_catch | ( | x, | |
| t | |||
| ) | else if ((t) == exc_type##x) |
Definition at line 110 of file pxsup2dast.c.
| #define exc_catchall else |
Definition at line 118 of file pxsup2dast.c.
| #define exc_cleanup | ( | ) | EXC.m_last = NULL; |
Definition at line 121 of file pxsup2dast.c.
| #define exc_end | ( | x | ) | else __exc_throw(exc_type##x); EXC.m_last = exc_s##x.m_prev; } while (0) |
Definition at line 112 of file pxsup2dast.c.
| #define exc_endall | ( | x | ) | EXC.m_last = exc_s##x.m_prev; } while (0) |
Definition at line 119 of file pxsup2dast.c.
| #define exc_fthrow | ( | x | ) | for (EXC.m_last = exc_p##x;) ex_throw |
Definition at line 116 of file pxsup2dast.c.
| #define exc_ftry | ( | x | ) |
Definition at line 103 of file pxsup2dast.c.
| #define exc_return | ( | x | ) | for (EXC.m_last = exc_p##x;) return |
Definition at line 114 of file pxsup2dast.c.
| #define exc_try | ( | x | ) |
Definition at line 97 of file pxsup2dast.c.
| #define GCCATTR_CONST __attribute ((const)) |
Definition at line 69 of file pxsup2dast.c.
| #define GCCATTR_NORETURN __attribute ((noreturn)) |
Definition at line 68 of file pxsup2dast.c.
| #define GCCATTR_PRINTF | ( | m, | |
| n | |||
| ) | __attribute__ ((format (printf, m, n))) |
Definition at line 66 of file pxsup2dast.c.
| #define GCCATTR_UNUSED __attribute ((unused)) |
Definition at line 67 of file pxsup2dast.c.
Definition at line 199 of file pxsup2dast.c.
| typedef int16_t ei16 |
Definition at line 53 of file pxsup2dast.c.
| typedef int32_t ei32 |
Definition at line 54 of file pxsup2dast.c.
| typedef int8_t ei8 |
Definition at line 52 of file pxsup2dast.c.
Definition at line 53 of file pxsup2dast.c.
| typedef uint32_t eu32 |
Definition at line 54 of file pxsup2dast.c.
| typedef uint8_t eu8 |
Definition at line 52 of file pxsup2dast.c.
| typedef int_fast16_t fi16 |
Definition at line 61 of file pxsup2dast.c.
| typedef int_fast32_t fi32 |
Definition at line 62 of file pxsup2dast.c.
| typedef int_fast8_t fi8 |
Definition at line 60 of file pxsup2dast.c.
| typedef uint_fast16_t fu16 |
Definition at line 61 of file pxsup2dast.c.
| typedef uint_fast32_t fu32 |
Definition at line 62 of file pxsup2dast.c.
| typedef uint_fast8_t fu8 |
Definition at line 60 of file pxsup2dast.c.
| typedef int_least16_t li16 |
Definition at line 57 of file pxsup2dast.c.
| typedef int_least32_t li32 |
Definition at line 58 of file pxsup2dast.c.
| typedef int_least8_t li8 |
Definition at line 56 of file pxsup2dast.c.
| typedef uint_least16_t lu16 |
Definition at line 57 of file pxsup2dast.c.
| typedef uint_least32_t lu32 |
Definition at line 58 of file pxsup2dast.c.
| typedef uint_least8_t lu8 |
Definition at line 56 of file pxsup2dast.c.
| anonymous enum |
| Enumerator | |
|---|---|
| MiscError | |
| EOFIndicator | |
| IndexError | |
Definition at line 74 of file pxsup2dast.c.
|
static |
Definition at line 123 of file pxsup2dast.c.
Referenced by exc_throw().
Definition at line 396 of file pxsup2dast.c.
Referenced by sup2dast().
Definition at line 654 of file pxsup2dast.c.
Referenced by pxsubtitle().
Definition at line 660 of file pxsup2dast.c.
Referenced by pxsubtitle().
Definition at line 201 of file pxsup2dast.c.
Referenced by MythUIType::AdjustAlpha(), MythPlayerCaptionsUI::AdjustSubtitleDelay(), MythPlayerCaptionsUI::AdjustSubtitleZoom(), fsurround_decoder::Impl::block_decode(), AutoExpire::CalcParams(), ProgramInfo::CalculateRecordedProgress(), ProgramInfo::CalculateWatchedProgress(), MHResidentProgram::CallProgram(), V4LChannel::ChangePictureAttribute(), MythVideoColourSpace::ChangePictureAttribute(), Spectrogram::clamp(), Spectrum::clamp(), Piano::clamp(), fsurround_decoder::Impl::clamp_unit_mag(), ClassicCommDetector::CleanupFrameInfo(), clipcheck(), MythDisplay::ConfigureQtGUI(), MythVisualMonoScopeOpenGL::Draw(), MythVisualMonoScopeVulkan::Draw(), VideoVisualSpectrum::Draw(), MythUIGuideGrid::Finalize(), get_v4l2_attribute_value(), MHListGroup::GetCellItem(), MpegRecorder::GetFilteredAudioLayer(), MythVideoProfile::GetMaxCPUs(), SignalMonitorValue::GetNormalizedValue(), PlaybackState::GetWatchedPercent(), goom_update(), MythDVDBuffer::GuessPalette(), MythUIType::HandleAlphaPulse(), TV::HandleTrackAction(), MythUIAnimation::IncrementCurrentTime(), FormattedTextSubtitle608::Init(), MythDeinterlacer::Initialise(), TeletextReader::KeyPress(), FormattedTextSubtitle::Layout(), MythVideoProfile::LoadBestPreferences(), ProgramInfo::LoadProgramFromRecorded(), MHOctetString::MHOctetString(), MPEG2AudioBitrateSettings::MPEG2AudioBitrateSettings(), HLSReader::ParseM3U8(), SSDPReceiver::performSearch(), Piano::Piano(), ProcessSearchRequest(), RecordingInfo::RecordingInfo(), MythPower::RequestFeature(), UPNPScanner::ScheduleRenewal(), MusicCommon::seekback(), MusicCommon::seekforward(), MythFrontendService::SendMessage(), LCD::setChannelProgress(), VolumeBase::SetCurrentVolume(), LCD::setGenericProgress(), LCD::setMusicProgress(), MythBDOverlay::SetPalette(), Slide::SetPan(), MythVAAPIInteropGLX::SetPictureAttribute(), MpegRecorder::SetRecordingVolume(), MythUIScrollBar::SetSliderPosition(), MHBitmap::SetTransparency(), Synaesthesia::setupPalette(), MythUIProgressBar::SetUsed(), MpegRecorder::SetV4L2DeviceOptions(), SignalMonitorValue::SetValue(), V4L2util::SetVolume(), AudioOutputOSS::SetVolumeChannel(), LCDProcClient::setVolumeLevel(), MythPlayerUI::SetWatched(), MythUIWebBrowser::SetZoom(), TV::ShowOSDAskAllow(), BrowserConfig::slotSave(), SatIPChannel::Tune(), ProgramInfo::UpdateLastDelete(), DeleteMap::UpdateSeekAmount(), MythPlayerOverlayUI::UpdateSliderInfo(), MythPowerDBus::UpdateStatus(), MythMediaBuffer::WaitForAvail(), MythMediaBuffer::WaitForReadsAllowed(), yuv2rgb(), and Slide::Zoom().
|
static |
Definition at line 287 of file pxsup2dast.c.
Referenced by sup2dast().
|
static |
Definition at line 130 of file pxsup2dast.c.
Referenced by argpalette(), boundstr_read(), ifopalette(), pxsubtitle(), sup2dast(), xfopen(), xfseek0(), xmkdir(), xxfread(), and xxfwrite().
|
static |
Definition at line 278 of file pxsup2dast.c.
Referenced by samepalette(), and sup2dast().
Definition at line 305 of file pxsup2dast.c.
Referenced by pxsubtitle().
Definition at line 297 of file pxsup2dast.c.
Referenced by ifopalette().
Definition at line 311 of file pxsup2dast.c.
Referenced by pxsubtitle().
Definition at line 534 of file pxsup2dast.c.
Referenced by getpixelline().
Definition at line 548 of file pxsup2dast.c.
Referenced by makebitmap().
|
static |
Definition at line 351 of file pxsup2dast.c.
Referenced by sup2dast().
|
static |
Definition at line 607 of file pxsup2dast.c.
Referenced by pxsubtitle().
Definition at line 485 of file pxsup2dast.c.
Referenced by getpixelline().
|
static |
Definition at line 511 of file pxsup2dast.c.
Referenced by makebitmap().
|
static |
Definition at line 498 of file pxsup2dast.c.
Referenced by getpixelline().
|
static |
Definition at line 472 of file pxsup2dast.c.
Referenced by png4file_addpixel(), and png4file_close().
Definition at line 430 of file pxsup2dast.c.
Referenced by makebitmap().
|
static |
Definition at line 439 of file pxsup2dast.c.
Referenced by makebitmap().
|
static |
Definition at line 631 of file pxsup2dast.c.
Referenced by pxsubtitle().
|
static |
Definition at line 673 of file pxsup2dast.c.
Referenced by sup2dast().
Definition at line 223 of file pxsup2dast.c.
Referenced by set2palettes(), and MythVideoColourSpace::Update().
|
static |
Definition at line 884 of file pxsup2dast.c.
Referenced by sup2dast().
Definition at line 382 of file pxsup2dast.c.
Referenced by argpalette().
Definition at line 339 of file pxsup2dast.c.
Referenced by png4file_flush().
Definition at line 326 of file pxsup2dast.c.
Referenced by png4file_close(), png4file_init(), png4file_open(), and xxfwrite_uint32_be().
| int sup2dast | ( | const char * | supfile, |
| const char * | ifofile, | ||
| int | delay_ms | ||
| ) |
Definition at line 906 of file pxsup2dast.c.
Referenced by main_local().
|
static |
Definition at line 251 of file pxsup2dast.c.
Referenced by ifopalette(), png4file_open(), pxsubtitle(), samepalette(), and sup2dast().
|
static |
Definition at line 259 of file pxsup2dast.c.
Referenced by ifopalette(), and png4file_close().
|
static |
Definition at line 265 of file pxsup2dast.c.
Referenced by sup2dast().
Definition at line 177 of file pxsup2dast.c.
Referenced by ifopalette(), and pxsubtitle().
|
static |
Definition at line 188 of file pxsup2dast.c.
Referenced by png4file_close(), png4file_flush(), png4file_open(), and xxfwrite_uint32_be().
|
static |
Definition at line 344 of file pxsup2dast.c.
Referenced by png4file_close().
Definition at line 210 of file pxsup2dast.c.
Referenced by ifopalette(), and MythVideoColourSpace::Update().
| struct { ... } EXC |
Referenced by __exc_throw(), exc_throw(), and sup2dast().
| int m_buflen |
Definition at line 90 of file pxsup2dast.c.
| struct exc__state* m_last |
Definition at line 88 of file pxsup2dast.c.
| char m_msgbuf[1024] |
Definition at line 89 of file pxsup2dast.c.