Age | Commit message (Collapse) | Author |
|
|
|
Currently, this is satisfied in all locations where it is called,
but it is more prudent to add the check.
|
|
--HG--
extra : transplant_source : i%86L%8F_h%1D%DDv%DF%E4%2B%906%8B%FBM%87h%2A
|
|
When using a variable to store the result of strlen(), make sure its
type is size_t just like the function returns, rather than using a
smaller type like int.
--HG--
extra : transplant_source : %B0%D5%3B%D7%1Dy%0A%7E%7D%7C%023%08%B2%CE%D3t%0B3%D7
|
|
Instead of looping through the directive string as returned by
sscanf() and transforming each character to its uppercase version, use
strcasestr to run a case-insensitive sub-string search.
Also avoid runing multiple strlen() calls per each line, use strncpy
instead.
|
|
Whenever an allocated memory area is immediately filled in with a
string through strcpy() or strncpy(), replace the calls with the
appropriate strn?dup().
|
|
The xine_xmalloc() function is going to be deprecated, as its
behaviour is rarely needed as such, and it's thus misused.
With this, almost all uses of xine_xmalloc() with static size (for
instance the value returned by sizeof()) or with a size that is
guaranteed not to be zero (like strlen()+1) are replaced with calls to
either calloc(1, ...) or malloc().
malloc() is used whenever the allocated memory is going to be
immediately overwritten, while calloc() is used in every other case,
as it sets the whole memory area to zero.
--HG--
extra : transplant_source : %8F%98%EC%02%1E%83%F0s%06X%83C%205Y%80%B12%CC%E1
|
|
|
|
|
|
|
|
I watch a lot of movies with subtitles and I need "vobsub subtitles"
work in xine, then I decide to write this patch.
It may support SSA tags for all text subtiles (ssa, ass, srt, ...)
This patch :
1. Remove all SSA tags from stream (they are ugly : {\a6})
2. Handle some of them (b, i, a, an, pos). The other ones control
colours, shadow, animation, ... I can't make them work in an easy way.
3. Correct wrap algorithm which have minors bugs (we can see them only
with SSA patch...)
Modified files :
libsputext/demux_sputext.c
just remove unneeded code (which remove some of SSA-tags)
libsputext/xine_sputext_decoder.c
the main modified file.
video_out/video_out_xshm.c
video_out/video_out_xv.c
xine-engine/video_out.h
get video output (position and size). See below.
1.
Removing SSA tags is done in ogm_render_line_internal() like for
html-like tags. (this was done in the previous version of xine)
2.
b(bold) and i(italic) are implemented like html-ones, in
ogm_render_line_internal().
The other tags this patch support are :
aX : alignment in SSA-code
anX : alignment in numpad code
pos(X,Y) : position, depend on alignment
For those ones, I need in first a full-screen OSD, not a five lines one.
Then, I need to remember where the last subtitle was drawn, in order to
erase it. At last, I need a translation function to convert subtitle
coordinates in screen coordinates.
For this last point, I first write a full-screen translation (don't care
about blacks borders), but it's not really good: the 'pos' tag is
sometime used to point out something in the video. (Moreover, ASS spec
say we have to draw subtitle on the video)
For doing this, I need the real video output size and position, which
are only know by the video output driver! Then I had 4 VO properties
(in xine-engine/video_out.h) for video driver could give us those
informations.
I implement it only in xshm and xv drivers (I can't test other ones).
If video driver can't give us those informations, the patch fallback in
a full-screen translation.
3.
there was 3 problem with the wrap algorithm :
1. It was in double: exactly the same, twice. Look like a merge problem.
I remove one and all work fine.
2. It want to cut string in equivalent display length but it cut it in
equivalent byte length. In most cases, this is the same, but if we have
UTF-8 chars or long SSA-tags (which will not be displayed) the result is
strange.
3. If we have a too-long part (in bytes) of the string without spaces
(bad subtitle file or long SSA-code), the algorithm don't know what to
do. (this case is not handled)
I re-write the wrap algorithm to correct those problems. Note that my
version is slower than previous one : working with bytes is really
faster than computing text-length. Maybe I should had to propose an
other patch for this part...
|
|
--HG--
extra : transplant_source : %E0%D0%C5%8B%BEU%DD%24%5D7%1F%ADV%AD%EB%23%CBU%80%EB
|
|
For contributed code, leave whatever the version we last synced for is using
to make simpler future syncs.
|
|
CVS patchset: 8524
CVS date: 2007/01/19 01:05:24
|
|
constant string, and make the extensions and mrl vaiables usually declared when testing extension demux strategy constants too.
CVS patchset: 8523
CVS date: 2007/01/19 00:26:39
|
|
CVS patchset: 8515
CVS date: 2007/01/18 11:57:16
|
|
Consolidated multiple strncat() calls to snprintf().
CVS patchset: 8407
CVS date: 2006/12/08 16:26:10
|
|
(through backports), to avoid exporting unneeded internal symbols, making plugins' loading faster and use of internal copies of libraries more solid. It should automatically fall back to the old way in GCCs that does not support -fvisibility=hidden, but has to be tested carefully. No issues were found in the months of testing in Gentoo, but this requires special attention anyway.
CVS patchset: 8101
CVS date: 2006/07/10 22:08:12
|
|
(Diego Pettenò)
CVS patchset: 7985
CVS date: 2006/05/03 19:46:06
|
|
CVS patchset: 7892
CVS date: 2006/02/14 18:41:43
|
|
CVS patchset: 7776
CVS date: 2005/10/29 20:51:01
|
|
CVS patchset: 7775
CVS date: 2005/10/29 20:18:57
|
|
Incremented demux API version.
This is needed to unload plugins.
CVS patchset: 7385
CVS date: 2005/02/06 15:26:00
|
|
(closes bug #1086775)
CVS patchset: 7267
CVS date: 2004/12/17 13:38:23
|
|
and backwards compatible translation
Sorry, I got a litte tired proof-reading the patch, so their might be
bugs lurking around. I will give it some further examination and
(as necessary) fixing tomorrow.
CVS patchset: 7233
CVS date: 2004/12/12 22:00:47
|
|
CVS patchset: 7102
CVS date: 2004/11/03 19:17:54
|
|
CVS patchset: 7091
CVS date: 2004/10/30 14:29:23
|
|
CVS patchset: 7081
CVS date: 2004/10/27 22:22:25
|
|
(actually it works with glibc and sprintf, but not with snprintf)
CVS patchset: 6859
CVS date: 2004/07/27 18:06:45
|
|
* fixed lots of unprotected buffers, overlong subtitle lines would have
caused overflows
CVS patchset: 6833
CVS date: 2004/07/22 14:19:12
|
|
http://article.gmane.org/gmane.comp.video.xine.devel/9532
it is now up to demuxers to decide what the 0..65535 position means.
demuxers tested: ogg, voc, flac, rm, asf, vqa, vob, avi, y4m, au, mov, ts, mp3, mpg, wav, ra, mve
CVS patchset: 6686
CVS date: 2004/06/13 21:28:52
|
|
and enhanced subtitle parser.
CVS patchset: 6673
CVS date: 2004/06/11 09:47:29
|
|
please everybody watch out for spelling (and other) errors
CVS patchset: 6442
CVS date: 2004/04/26 17:50:06
|
|
CVS patchset: 6030
CVS date: 2004/01/12 17:35:14
|
|
* fix compiler warnings
CVS patchset: 5947
CVS date: 2003/12/24 17:34:49
|
|
Some formats define the end of a subtitle as the beginning of the
following. But using configurable timeout seems better.
* Three new formats of subtitles:
- jacobsub from mplayer (not tested by me)
- subviewer v2.0 from mplayer (not tested by me)
- subrip v0.9
* Change deprecated bzero() to memset()
CVS patchset: 5918
CVS date: 2003/12/17 13:41:05
|
|
CVS patchset: 5796
CVS date: 2003/11/26 19:43:26
|
|
BIG NOTE: use helpers to access to these informations (get/set/reset):
_x_{stream,meta}_info_{get,set,reset}()
are for internal use, don't use *_public() ones from inside the beast ;-)
Some wrongly names "xine_" fonction renaming.
CVS patchset: 5757
CVS date: 2003/11/16 23:33:42
|
|
(we should finish this before rc3.)
- stream_info and meta_info variables are private now.
obs: everything must be recompiled due xine_stream_t changes
CVS patchset: 5733
CVS date: 2003/11/15 14:54:30
|
|
CVS patchset: 5731
CVS date: 2003/11/15 13:01:00
|
|
CVS patchset: 5721
CVS date: 2003/11/11 18:44:50
|
|
care of seek() return value.
CVS patchset: 5684
CVS date: 2003/11/04 00:24:52
|
|
CVS patchset: 5683
CVS date: 2003/11/03 23:58:18
|
|
CVS patchset: 5501
CVS date: 2003/10/13 06:57:28
|
|
CVS patchset: 5303
CVS date: 2003/08/24 10:17:43
|
|
CVS patchset: 5242
CVS date: 2003/08/04 03:16:48
|
|
not sure this is need, but it must be harmless :)
patch by Marc Bevand
CVS patchset: 5235
CVS date: 2003/08/04 01:37:58
|
|
CVS patchset: 5211
CVS date: 2003/07/25 21:02:04
|
|
the "unsigned" is wrong)
CVS patchset: 5088
CVS date: 2003/06/22 16:53:04
|
|
CVS patchset: 4691
CVS date: 2003/04/26 20:15:52
|