summaryrefslogtreecommitdiff
path: root/libavcodec/libzvbi-teletextdec.c
Commit message (Collapse)AuthorAge
* avcodec: Add FF_CODEC_CAP_NOT_INIT_THREADSAFEAndreas Rheinhardt2022-07-18
| | | | | | | This is in preparation of switching the default init-thread-safety to a codec being init-thread-safe. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec: Add const to decoder packet data pointersAndreas Rheinhardt2022-07-09
| | | | | | | The packets given to decoder need not be writable, so it is best to access them via const uint8_t*. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/codec_internal: Constify AVPacket in decode_sub cbAndreas Rheinhardt2022-04-05
| | | | | | No subtitle decoder ever modifies the AVPacket given to it. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/codec_internal: Use union for FFCodec decode/encode callbacksAndreas Rheinhardt2022-04-05
| | | | | | | | | | | This is possible, because every given FFCodec has to implement exactly one of these. Doing so decreases sizeof(FFCodec) and therefore decreases the size of the binary. Notice that in case of position-independent code the decrease is in .data.rel.ro, so that this translates to decreased memory consumption. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/codec_internal: Add FFCodec.decode_subAndreas Rheinhardt2022-04-05
| | | | | | | | | This increases type-safety by avoiding conversions from/through void*. It also avoids the boilerplate "AVSubtitle *sub = data;" line for subtitle decoders. Its only downside is that it increases sizeof(FFCodec), yet this can be more than offset lateron. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/codec_internal: Add FFCodec, hide internal part of AVCodecAndreas Rheinhardt2022-03-21
| | | | | | | | | | | | | | | | Up until now, codec.h contains both public and private parts of AVCodec. This exposes the internals of AVCodec to users and leads them into the temptation of actually using them and forces us to forward-declare structures and types that users can't use at all. This commit changes this by adding a new structure FFCodec to codec_internal.h that extends AVCodec, i.e. contains the public AVCodec as first member; the private fields of AVCodec are moved to this structure, leaving codec.h clean. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec: Constify AVCodecsAndreas Rheinhardt2021-04-27
| | | | | | | | | | Given that the AVCodec.next pointer has now been removed, most of the AVCodecs are not modified at all any more and can therefore be made const (as this patch does); the only exceptions are the very few codecs for external libraries that have a init_static_data callback. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec: Remove deprecated AVPicture APIAndreas Rheinhardt2021-04-27
| | | | | | | Deprecated in a17a7661906ba295d67afd80ac0770422e1b02b3. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/libzvbi-teletextdec: fix txt_default_region limitsMarton Balint2020-06-14
| | | | | | | Max region ID is 87. Also the region affects not only the G0 charset but G2 and the national subset as well. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: replace data_size with got_sub_ptr for better ↵Limin Wang2020-03-25
| | | | | | | readability Signed-off-by: Limin Wang <lance.lmwang@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/libzvbi-teletextdec: add option to set default G0 character setKirill Savkov2020-02-24
| | | | | Signed-off-by: Kirill Savkov <k.savkov@inventos.ru> Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: add formatted ass outputMarton Balint2018-09-30
| | | | | | | Inspired by the VideoLAN text decoder and its port to FFmpeg made by Aman Gupta. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: propagate ERASE_PAGE flag for repeated subtitle ↵Marton Balint2018-06-20
| | | | | | | | | | | | | page headers This works around a libzvbi bug (a corner case in the teletext spec): https://sourceforge.net/p/zapping/bugs/203/ https://sourceforge.net/p/zapping/patches/20/ Fixes samples/ffmpeg-bugs/trac/ticket2086/RBT_20100801_1835.ts. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: add support for selecting subtitle pages onlyMarton Balint2018-06-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: remove DEBUG codeMarton Balint2018-05-06
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: allow -1 subtitle duration and make it the defaultMarton Balint2018-05-06
| | | | | | | Most decoders (pgssubdec, ccaption_dec) are using -1 or UINT32_MAX for a subtitle event which should be cleared at the next event. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec: add metadata to identify wrappers and hardware decoderswm42017-12-14
| | | | | | | | | | | | | | | | | | | | | Explicitly identify decoder/encoder wrappers with a common name. This saves API users from guessing by the name suffix. For example, they don't have to guess that "h264_qsv" is the h264 QSV implementation, and instead they can just check the AVCodec .codec and .wrapper_name fields. Explicitly mark AVCodec entries that are hardware decoders or most likely hardware decoders with new AV_CODEC_CAPs. The purpose is allowing API users listing hardware decoders in a more generic way. The proposed AVCodecHWConfig does not provide this information fully, because it's concerned with decoder configuration, not information about the fact whether the hardware is used or not. AV_CODEC_CAP_HYBRID exists specifically for QSV, which can have software implementations in case the hardware is not capable. Based on a patch by Philip Langdale <philipl@overt.org>. Merges Libav commit 47687a2f8aca3f65b6fdd117b1cb66a7409a7fd1.
* lavc/libzvbi: remove deprecated API usageJosh de Kock2017-02-12
| | | | | Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Josh de Kock <josh@itanimul.li>
* avcodec/libzvbi-teletextdec: Remove unused variableMichael Niedermayer2016-02-28
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavc/options: add ass_ro_flush_noop to flags2Clément Bœsch2016-02-26
|
* lavc: allow subtitle text format to be ASS without timingClément Bœsch2016-02-26
|
* avcodec/libzvbi-teletextdec: use common functions for matching data_unit_id ↵Marton Balint2016-02-19
| | | | | | and data_identifier Signed-off-by: Marton Balint <cus@passwd.hu>
* lavc/libzvbi-teletextdec: add support for setting background opacityMarton Balint2016-01-25
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* lavc/libzvbi-teletextdec: remove cmax variableMarton Balint2016-01-25
| | | | | | Use VBI_NB_COLORS instead. Signed-off-by: Marton Balint <cus@passwd.hu>
* lavc/libzvbi-teletextdec: use the built-in transparent color for transparent ↵Marton Balint2016-01-25
| | | | | | background Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec: properly check pkt_timebase for validityHendrik Leppkes2015-12-28
| | | | | | Unset/invalid timebases have a zero numerator. This makes the checks consistent with other timebase checks and fixes an integer division by 0.
* avcodec/libzvbi-teletextdec: Remove unused variable retMichael Niedermayer2015-11-04
| | | | | | Fixes: libavcodec/libzvbi-teletextdec.c:232:9: warning: unused variable ret [-Wunused-variable] Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* libzvbi-teletextdec: fix AVSubtitleRect pict compatiblity codeMarton Balint2015-10-24
| | | | | | Only set pict if we got a valid rect. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/libzvbi-teletextdec: Add variable to fix buildMichael Niedermayer2015-10-22
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/libzvbi: Update for AVSubtitleRect changesHendrik Leppkes2015-10-22
|
* Replace av_dlog with ff_dlog.Ronald S. Bultje2015-08-18
| | | | | ff_dlog checks compilability, and is non-public. av_dlog is deprecated and no longer exists if FF_API_DLOG=0.
* Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'Michael Niedermayer2015-07-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'def97856de6021965db86c25a732d78689bd6bb0': lavc: AV-prefix all codec capabilities Conflicts: cmdutils.c ffmpeg.c ffplay.c libavcodec/8svx.c libavcodec/aacenc.c libavcodec/ac3dec.c libavcodec/adpcm.c libavcodec/alac.c libavcodec/atrac3plusdec.c libavcodec/bink.c libavcodec/dnxhddec.c libavcodec/dvdec.c libavcodec/dvenc.c libavcodec/ffv1dec.c libavcodec/ffv1enc.c libavcodec/fic.c libavcodec/flacdec.c libavcodec/flacenc.c libavcodec/flvdec.c libavcodec/fraps.c libavcodec/frwu.c libavcodec/gifdec.c libavcodec/h261dec.c libavcodec/hevc.c libavcodec/iff.c libavcodec/imc.c libavcodec/libopenjpegdec.c libavcodec/libvo-aacenc.c libavcodec/libvorbisenc.c libavcodec/libvpxdec.c libavcodec/libvpxenc.c libavcodec/libx264.c libavcodec/mjpegbdec.c libavcodec/mjpegdec.c libavcodec/mpegaudiodec_float.c libavcodec/msmpeg4dec.c libavcodec/mxpegdec.c libavcodec/nvenc_h264.c libavcodec/nvenc_hevc.c libavcodec/pngdec.c libavcodec/qpeg.c libavcodec/ra288.c libavcodec/rv10.c libavcodec/s302m.c libavcodec/sp5xdec.c libavcodec/takdec.c libavcodec/tiff.c libavcodec/tta.c libavcodec/utils.c libavcodec/v210dec.c libavcodec/vp6.c libavcodec/vp9.c libavcodec/wavpack.c libavcodec/yop.c Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/ass: add ASS trailing \r\n in one single placeClément Bœsch2014-10-19
|
* avcodec/libzvbi-teletextdec: remove * 1Michael Niedermayer2014-04-08
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* libzvbi-teletextdec: split dvb packet to slicesMarton Balint2014-03-08
| | | | | | | | | | | | Instead of using the demux function of libzvbi to split the packet to slices (vbi lines), lets do it ourselves. - eliminates the 1 frame delay between page input and output - handles non-ascending line numbers more gracefully - enables us to return error codes on some invalid packets instead of silently ignoring them Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: use av_dlog where possibleMarton Balint2014-03-08
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* Fix FSF address in colormatrix and libzvbi license headers.Carl Eugen Hoyos2014-02-22
| | | | | As reported by irc user aca. The files in compat/avisynth are maintained elsewhere, no changes.
* libzvbi-teletextdec: set bitmap teletext canvas dimensionsMarton Balint2013-12-14
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: add chopped top row size to y offsetMarton Balint2013-12-14
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: use defined constants for bitmap char width and heightMarton Balint2013-12-14
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: cosmeticsMarton Balint2013-12-14
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: propagate errors generated in page handlerMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: dont ignore memory allocation error silentlyMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: output ass subtitles instead of plain textMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: use AVBPrint for whitespace cleanupMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: use option constants instead of stringsMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: fix indentation after last commitMarton Balint2013-11-10
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* libzvbi-teletextdec: support multiple teletext pages in a single packetMarton Balint2013-11-10
| | | | | | | | After this patch, if a packet contains multiple teletext pages, the teletext decoder can return the fist page and store the remaining pages in memory, and return them to the user on the next calls to avcodec_decode_subtitle2. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec: fix old codec idsMichael Niedermayer2013-10-28
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* cosmetics: group remaining .name and .long_name.Clément Bœsch2013-10-04
| | | | See b2bed9325.