summaryrefslogtreecommitdiffstats
path: root/stream/stream_dvd.c
Commit message (Collapse)AuthorAgeFilesLines
* stream_dvd: fix angle mathRudolf Polzer2012-12-221-8/+7
| | | | | Stop changing the dvd_angle variable while opening a DVD. Fixes issues with multiple dvd:// URLs on one command line.
* stream_dvd: add a stream_seek() callRudolf Polzer2012-12-071-0/+2
| | | | | This fixes use of -chapter together with -correct-pts and demux_lavf and stream_dvd.
* stream: fix dvd:// + cache crashingwm42012-11-201-1/+1
| | | | | | The language string was dynamically allocated, which completely fails if the cache is forked (which it usually is). Change it back to a fixed length string, like the original code had it.
* stream, demux: replace off_t with int64_twm42012-11-201-10/+10
| | | | | | On reasonable systems, these types were the same anyway. Even on unreasonable systems (seriously, which?), this may reduce potential breakage.
* Rename directories, move files (step 2 of 2)wm42012-11-121-4/+4
| | | | | | | | | | | | Finish renaming directories and moving files. Adjust all include statements to make the previous commit compile. The two commits are separate, because git is bad at tracking renames and content changes at the same time. Also take this as an opportunity to remove the separation between "common" and "mplayer" sources in the Makefile. ("common" used to be shared between mplayer and mencoder.)
* stream: add STREAM_CTRL_GET_CURRENT_TITLEib2012-10-301-0/+5
| | | | | | | | Add new stream control command STREAM_CTRL_GET_CURRENT_TITLE for DVDs. This provides the current title (aka track) number of a DVD. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@35263 b3059339-0415-0410-9bf9-f77b7e298cf2
* Rename to "mpv"wm42012-10-121-1/+1
| | | | | | | | | | | | | | | | | | This changes the name of this project to mpv. Most user-visible mentions of "MPlayer" and "mplayer" are changed to "mpv". The binary name and the default config file location are changed as well. The new default config file location is: ~/.mpv/ Remove etc/mplayer.desktop. Apparently this was for the MPlayer GUI, which has been removed from mplayer2 ages ago. We don't have a logo, and the MS Windows resource files sort-of require one, so leave etc/mplayer.ico/.xpm as-is. Remove the debian and rpm packaging scripts. These contained outdated dependencies and likely were more harmful than useful. (Patches which add working and well-tested packaging are welcome.)
* core: fix DVD subtitle selectionwm42012-09-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add all subtitle tracks as reported by libdvdread at playback start. Display language for subtitle and audio tracks. This commit restores these features to the state when demux_mpg was default for DVD playback, and makes them work with demux_lavf and the recent changes to subtitle selection in the frontend. demux_mpg, which was the default demuxer for DVD playback, reordered the subtitle streams according to the "logical" subtitle track number, which conforms to the track layout reported by libdvdread, and is what stream_dvd expects for the STREAM_CTRL_GET_LANG call. demux_lavf, on the other hand, adds the streams in the order it encounters them in the MPEG stream. It seems this order is essentially random, and can't be mapped easily to what stream_dvd expects. Solve this by making demux_lavf hand out the MPEG stream IDs (using the demuxer_id field). The MPEG IDs are mapped by mplayer.c by special casing DVD playback (map_id_from/to_demuxer() functions). This mapping is essentially the same what demux_mpg did. Making demux_lavf reorder the streams is out of the question, because its stream handling is already messy enough. (Note that demux_lavf doesn't export stream IDs for other formats, because most time libavformat demuxers do not set AVStream.id, and we don't know which demuxers do. But we know that MPEG is safe.) Another major complication is that subtitle tracks are added lazily, as soon as the demuxer encounters the first subtitle packet for a given subtitle stream. Add the streams in advance. If a yet non-existent stream is selected, demux_lavf must be made to auto-select that subtitle stream as soon as it is added. Otherwise, the first subtitle packet would be lost. This is done by DEMUXER_CTRL_PRESELECT_SUBTITLE. demux_mpg didn't need this: the frontend code could just set ds->id to the desired stream number. But demux_lavf's stream IDs don't map directly to the stream number as used by libdvdread, which is why this hack is needed.
* commands, dvd, dvdnav, bluray: cleanup sub/audio track language displaymplayer-svn2012-08-031-2/+20
| | | | | | | | | | | | | | | | | | | | | Code cleanup: Use a stream_control instead of global functions to get the language associate with a audio or subtitle stream from the streaming layer. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34736 b3059339-0415-0410-9bf9-f77b7e298cf2 Support showing the stream language with br:// playback. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34737 b3059339-0415-0410-9bf9-f77b7e298cf2 Fix DVDs showing the subtitle language as "unknown" for a long time. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34777 b3059339-0415-0410-9bf9-f77b7e298cf2 Author: reimar Note: heavily modified by wm4 for this fork of mplayer.
* stream: add new stream control command STREAM_CTRL_GET_NUM_TITLESmplayer-svn2012-08-031-0/+5
| | | | | | | | | This provides the total number of titles (aka tracks) of CDs / VCDs / DVDs. Additionally, add a titles property to the get_property slave command. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34474 b3059339-0415-0410-9bf9-f77b7e298cf2 Author: ib
* stream_dvd: fix dvd_get_current_time()reimar2011-07-061-5/+5
| | | | | | Fix dvd_get_current_time so the cell argument actually has a purpose. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33603 b3059339-0415-0410-9bf9-f77b7e298cf2
* options: change -alang and -slang to use string list typeClément Bœsch2011-04-201-14/+9
| | | | | | | | | There is no reason to use manual language list splitting when an automatic split function is already available. Some types change from "unsigned char" to "char", but this shouldn't cause issues since [as]lang settings are unlikely to have characters above 127.
* stream_dvd: fill_buffer(): use given buffer, not stream's defaultreimar2010-11-081-2/+5
| | | | | | | | | Fix dvd:// fill_buffer function to actually write into the specified buffer and check that the buffer is sufficiently large. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32591 b3059339-0415-0410-9bf9-f77b7e298cf2 git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32592 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd: minor cleanupreimar2010-11-081-7/+4
| | | | | | | | | | | | | | Remove a pointless and stupid condition. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32588 b3059339-0415-0410-9bf9-f77b7e298cf2 Change code to something understandable (but equivalent). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32589 b3059339-0415-0410-9bf9-f77b7e298cf2 100l, add missing return. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32590 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd: millisecond accuracy for chapters in -identify outputcigaes2010-11-071-3/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32539 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd[nav]: Add const qualifiers to string argumentsreimar2010-11-021-2/+2
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31957 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd: Improve seeking by positiondiego2010-11-021-15/+8
| | | | | | | | | The current code takes the angle into account. This is a mistake since the position is independent of the angle. patch by Olivier Rolland, billl users.sourceforge net git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31895 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd: Improve seeking by chaptersdiego2010-11-021-5/+12
| | | | | | | | | | | The current code seeks to the start of the chapter. From this position, it then tries to figure out the starting cell. This is completely suboptimal and error prone since the starting cell can be directly deduced from the chapter. patch by Olivier Rolland, billl users.sourceforge net git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31894 b3059339-0415-0410-9bf9-f77b7e298cf2
* stream_dvd: fix incorrect assumption about chapter countdiego2010-11-021-10/+38
| | | | | | | | | Fix the incorrect assumption that the number of chapters of a DVD title is equal to the number of cells. patch by Olivier Rolland, billl users.sourceforge net git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31893 b3059339-0415-0410-9bf9-f77b7e298cf2
* cosmetics: "struct vf_instance* vf" -> "struct vf_instance *vf"Uoti Urpala2010-05-291-3/+6
| | | | | | | Change 'struct vf_instance' pointer arguments to more standard style as in the subject. Also some other minor formatting fixes. Patch by Diego Biurrun.
* options: move -chapter values to option structUoti Urpala2010-04-251-38/+0
| | | | | | | | | | | -chapter can optionally take a range with a start and an end. Add a new option type which supports such values and use that instead of a custom per-option function. This commit also fixes a build configuration bug: before the availability of the -chapter option depended on DVD functionality being enabled in the binary, even though the option works with other sources too.
* Delete things related to old translation systemUoti Urpala2010-03-101-1/+0
| | | | | Remove the help/ subdirectory, configure code to create toplevel help_mp.h, and all the '#include "help_mp.h"' lines from .c files.
* Merge svn changes up to r30475Uoti Urpala2010-03-091-1/+17
|\
| * Add license header to all files missing it in the stream subdirectory.diego2010-01-301-1/+17
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30468 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r29962Uoti Urpala2009-11-231-1/+1
|\|
| * Finally rename the STREAM_SEEK define to MP_STREAM_SEEK, there are just too manyreimar2009-11-221-1/+1
| | | | | | | | | | | | | | name clashes, in particular with Windows headers (which define STREAM_SEEK as an enum type). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29962 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r29912Uoti Urpala2009-11-161-91/+0
|\|
| * Move headers related to setting dvd speed to dvd_common.reimar2009-11-111-14/+0
| | | | | | | | | | | | | | This makes -dvd-speed work again. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29894 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Move dvd_speed and dvd_set_speed to dvd_common and implement -dvd-speedreimar2009-11-101-73/+0
| | | | | | | | | | | | | | support for dvdnav. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29890 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Move arrays used by both dvd and dvdnav to dvd_common.reimar2009-11-101-3/+0
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29889 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Share dvd_device extern declaration between dvd and dvdnav.reimar2009-11-101-1/+0
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29887 b3059339-0415-0410-9bf9-f77b7e298cf2
| * whitespace cosmetics: Remove all trailing whitespace.diego2009-05-131-9/+9
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29305 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Replace libavutil internal header #includes with MPlayer copiesUoti Urpala2009-07-261-1/+1
| | | | | | | | | | | | Change #include lines for libavutil/intreadwrite.h, libavutil/bswap.h and libavutil/x86_cpu.h to use the MPlayer file under ffmpeg_files/ instead.
* | Remove trailing whitespace from most filesUoti Urpala2009-07-071-9/+9
| |
* | Translation system changes part 2: replace macros by stringsAmar Takhar2009-07-071-28/+28
| | | | | | | | | | Replace all MSGTR_ macros in the source by the corresponding English string.
* | Translation system changes part 1: wrap translated stringsAmar Takhar2009-07-071-28/+28
| | | | | | | | | | Replace mp_msg() calls which have a translated string as the format argument with mp_tmsg and add _() around all other translated strings.
* | Merge svn changes up to r29134Uoti Urpala2009-04-021-1/+0
|\|
| * Remove unused variable along with the related warning.diego2009-04-011-1/+0
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29122 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r29117Uoti Urpala2009-04-011-2/+2
|\|
| * 100l, revert r29082, I missed that the vts comparison should be ↵reimar2009-03-281-1/+5
| | | | | | | | | | | | case-insensitive. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29084 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Reindentreimar2009-03-281-2/+2
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29083 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Simplify extracting title number from ifo namereimar2009-03-281-5/+1
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29082 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Simplify detection of .ifo extension.reimar2009-03-271-2/+2
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29078 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r28310Uoti Urpala2009-01-151-1/+11
|\| | | | | | | | | | | | | | | The libdvdread4 and libdvdnav directories, which are externals in the svn repository, are at least for now not included in any form. I added configure checks to automatically disable internal libdvdread and libdvdnav if the corresponding directories are not present; if they're added manually then things work the same as in svn.
| * Fix DVD seek_to_chapter: the title number must be converted to a per-VTSreimar2009-01-011-0/+9
| | | | | | | | | | | | | | title number first. Also add a few out-of-bounds checks just in case. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28226 b3059339-0415-0410-9bf9-f77b7e298cf2
| * Work around a dvdread bug where DVDReadBlocks would return values < 0 on ↵reimar2008-12-311-1/+2
| | | | | | | | | | | | | | | | | | | | read error, causing hangs e.g. when seeking to the very last chapter (which would read beyond the size of the DVD). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28216 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to 27824Uoti Urpala2008-10-251-1/+1
|\| | | | | | | | | | | | | | | | | | | Conflicts: cfg-common-opts.h libmpcodecs/dec_video.c libmpcodecs/vd.c libvo/x11_common.h mplayer.c stream/cache2.c
| * Replace typeof by __typeof__, the former is a non-portable GNU extension.diego2008-10-201-1/+1
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27807 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r27649Uoti Urpala2008-09-201-1/+1
|\| | | | | | | | | | | | | Conflicts: Makefile configure libvo/x11_common.c
| * With -identify, ID_DVD_VOLUME_ID is not shown on some systems.diego2008-09-161-1/+1
| | | | | | | | | | | | | | | | Using DVDISOVolumeInfo instead of DVDUDFVolumeInfo fixes this. patch by Mathieu SCHROETER, mathieu.schroeter gamesover ch git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27631 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Merge svn changes up to r27514Uoti Urpala2008-09-031-0/+3
|\|
| * Print DVD volume ID with -identify.reimar2008-08-301-0/+3
| | | | | | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27497 b3059339-0415-0410-9bf9-f77b7e298cf2
* | Make various functions staticUoti Urpala2008-08-121-3/+3
|/
* in dvd streams the title part ranges from 1 to 99nicodvb2008-07-121-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27267 b3059339-0415-0410-9bf9-f77b7e298cf2
* avoid unnecessary strdup(); patch by Aurelnicodvb2008-07-061-1/+1
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27226 b3059339-0415-0410-9bf9-f77b7e298cf2
* cosmetics: in ifo_stream_oped() aligned the prototype to the stylenicodvb2008-07-041-9/+8
| | | | | | | | | of the rest of the file and renamed dvd_priv to spriv (it's a stream_priv_s*, while dvd_priv is used for other purposes in the rest of the file) git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27198 b3059339-0415-0410-9bf9-f77b7e298cf2
* in ifo_stream_open() propagate the device based on the dirname of ↵nicodvb2008-07-041-0/+1
| | | | | | stream->url; patch by Mathieu SCHROETER mathieu.schroeter gamesover ch git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27197 b3059339-0415-0410-9bf9-f77b7e298cf2
* dvd_device must be handled exclusively by the option parser; it can't be ↵nicodvb2008-07-041-2/+0
| | | | | | changed at will in ifo_stream_open() git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27196 b3059339-0415-0410-9bf9-f77b7e298cf2
* added support for the device part in the url; patch bynicodvb2008-07-041-8/+17
| | | | | | | Mathieu SCHROETER mathieu.schroeter gamesover ch git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27195 b3059339-0415-0410-9bf9-f77b7e298cf2
* Add basic support for stream controls with cache enabled.reimar2008-05-241-7/+0
| | | | git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26865 b3059339-0415-0410-9bf9-f77b7e298cf2
* -chapter is now handled uniformly calling demuxer_seek_chapter() insteadnicodvb2008-02-111-23/