[MPlayer-cvslog] r27018 - in trunk: command.c mplayer.c stream/stream_dvdnav.c stream/stream_dvdnav.h

ben subversion at mplayerhq.hu
Sat Jun 7 14:57:24 CEST 2008


Author: ben
Date: Sat Jun  7 14:57:23 2008
New Revision: 27018

Log:
Rename some functions as they are mplayer related and not
from libdvdnav public API.



Modified:
   trunk/command.c
   trunk/mplayer.c
   trunk/stream/stream_dvdnav.c
   trunk/stream/stream_dvdnav.h

Modified: trunk/command.c
==============================================================================
--- trunk/command.c	(original)
+++ trunk/command.c	Sat Jun  7 14:57:23 2008
@@ -826,7 +826,7 @@ static int mp_property_audio(m_option_t 
 
 #ifdef USE_DVDNAV
 	    else if (mpctx->stream->type == STREAMTYPE_DVDNAV)
-		dvdnav_lang_from_aid(mpctx->stream, audio_id, lang);
+		mp_dvdnav_lang_from_aid(mpctx->stream, audio_id, lang);
 #endif
 	    *(char **) arg = malloc(64);
 	    snprintf(*(char **) arg, 64, "(%d) %s", audio_id, lang);
@@ -1342,7 +1342,7 @@ static int mp_property_sub(m_option_t * 
 	if (mpctx->stream->type == STREAMTYPE_DVDNAV) {
 	    if (vo_spudec && dvdsub_id >= 0) {
 		unsigned char lang[3];
-		if (dvdnav_lang_from_sid(mpctx->stream, dvdsub_id, lang)) {
+		if (mp_dvdnav_lang_from_sid(mpctx->stream, dvdsub_id, lang)) {
 		    snprintf(*(char **) arg, 63, "(%d) %s", dvdsub_id, lang);
 		    return M_PROPERTY_OK;
 		}

Modified: trunk/mplayer.c
==============================================================================
--- trunk/mplayer.c	(original)
+++ trunk/mplayer.c	Sat Jun  7 14:57:23 2008
@@ -3212,12 +3212,12 @@ if(mpctx->stream->type==STREAMTYPE_DVD){
 #ifdef USE_DVDNAV
 if(mpctx->stream->type==STREAMTYPE_DVDNAV){
   current_module="dvdnav lang->id";
-  if(audio_id==-1) audio_id=dvdnav_aid_from_lang(mpctx->stream,audio_lang);
+  if(audio_id==-1) audio_id=mp_dvdnav_aid_from_lang(mpctx->stream,audio_lang);
   if(dvdsub_lang && dvdsub_id==-2) dvdsub_id=-1;
-  if(dvdsub_lang && dvdsub_id==-1) dvdsub_id=dvdnav_sid_from_lang(mpctx->stream,dvdsub_lang);
+  if(dvdsub_lang && dvdsub_id==-1) dvdsub_id=mp_dvdnav_sid_from_lang(mpctx->stream,dvdsub_lang);
   // setup global sub numbering
   mpctx->global_sub_indices[SUB_SOURCE_DEMUX] = mpctx->global_sub_size; // the global # of the first demux-specific sub.
-  mpctx->global_sub_size += dvdnav_number_of_subs(mpctx->stream);
+  mpctx->global_sub_size += mp_dvdnav_number_of_subs(mpctx->stream);
   current_module=NULL;
 }
 #endif

Modified: trunk/stream/stream_dvdnav.c
==============================================================================
--- trunk/stream/stream_dvdnav.c	(original)
+++ trunk/stream/stream_dvdnav.c	Sat Jun  7 14:57:23 2008
@@ -682,12 +682,12 @@ void mp_dvdnav_update_mouse_pos(stream_t
 }
 
 /**
- * \brief dvdnav_aid_from_lang() returns the audio id corresponding to the language code 'lang'
+ * \brief mp_dvdnav_aid_from_lang() returns the audio id corresponding to the language code 'lang'
  * \param stream: - stream pointer
  * \param lang: 2-characters language code[s], eventually separated by spaces of commas
  * \return -1 on error, current subtitle id if successful
  */
-int dvdnav_aid_from_lang(stream_t *stream, unsigned char *language) {
+int mp_dvdnav_aid_from_lang(stream_t *stream, unsigned char *language) {
   dvdnav_priv_t * priv = stream->priv;
   int k;
   uint8_t format, lg;
@@ -722,13 +722,13 @@ int dvdnav_aid_from_lang(stream_t *strea
 }
 
 /**
- * \brief dvdnav_lang_from_aid() assigns to buf the language corresponding to audio id 'aid'
+ * \brief mp_dvdnav_lang_from_aid() assigns to buf the language corresponding to audio id 'aid'
  * \param stream: - stream pointer
  * \param sid: physical subtitle id
  * \param buf: buffer to contain the 2-chars language string
  * \return 0 on error, 1 if successful
  */
-int dvdnav_lang_from_aid(stream_t *stream, int aid, unsigned char *buf) {
+int mp_dvdnav_lang_from_aid(stream_t *stream, int aid, unsigned char *buf) {
   uint8_t lg;
   uint16_t lang;
   dvdnav_priv_t * priv = stream->priv;
@@ -747,12 +747,12 @@ int dvdnav_lang_from_aid(stream_t *strea
 
 
 /**
- * \brief dvdnav_sid_from_lang() returns the subtitle id corresponding to the language code 'lang'
+ * \brief mp_dvdnav_sid_from_lang() returns the subtitle id corresponding to the language code 'lang'
  * \param stream: - stream pointer
  * \param lang: 2-characters language code[s], eventually separated by spaces of commas
  * \return -1 on error, current subtitle id if successful
  */
-int dvdnav_sid_from_lang(stream_t *stream, unsigned char *language) {
+int mp_dvdnav_sid_from_lang(stream_t *stream, unsigned char *language) {
   dvdnav_priv_t * priv = stream->priv;
   uint8_t lg, k;
   uint16_t lang, lcode;
@@ -774,13 +774,13 @@ int dvdnav_sid_from_lang(stream_t *strea
 }
 
 /**
- * \brief dvdnav_lang_from_sid() assigns to buf the language corresponding to subtitle id 'sid'
+ * \brief mp_dvdnav_lang_from_sid() assigns to buf the language corresponding to subtitle id 'sid'
  * \param stream: - stream pointer
  * \param sid: physical subtitle id
  * \param buf: buffer to contain the 2-chars language string
  * \return 0 on error, 1 if successful
  */
-int dvdnav_lang_from_sid(stream_t *stream, int sid, unsigned char *buf) {
+int mp_dvdnav_lang_from_sid(stream_t *stream, int sid, unsigned char *buf) {
     uint8_t lg;
     uint16_t lang;
     dvdnav_priv_t *priv = stream->priv;
@@ -795,11 +795,11 @@ int dvdnav_lang_from_sid(stream_t *strea
 }
 
 /**
- * \brief dvdnav_number_of_subs() returns the count of available subtitles
+ * \brief mp_dvdnav_number_of_subs() returns the count of available subtitles
  * \param stream: - stream pointer
  * \return 0 on error, something meaningful otherwise
  */
-int dvdnav_number_of_subs(stream_t *stream) {
+int mp_dvdnav_number_of_subs(stream_t *stream) {
   dvdnav_priv_t * priv = stream->priv;
   uint8_t lg, k, n=0;
 

Modified: trunk/stream/stream_dvdnav.h
==============================================================================
--- trunk/stream/stream_dvdnav.h	(original)
+++ trunk/stream/stream_dvdnav.h	Sat Jun  7 14:57:23 2008
@@ -16,11 +16,11 @@ typedef struct {
   uint32_t palette;
 } nav_highlight_t;
 
-int dvdnav_number_of_subs(stream_t *stream);
-int dvdnav_aid_from_lang(stream_t *stream, unsigned char *language);
-int dvdnav_lang_from_aid(stream_t *stream, int id, unsigned char *buf);
-int dvdnav_sid_from_lang(stream_t *stream, unsigned char *language);
-int dvdnav_lang_from_sid(stream_t *stream, int sid, unsigned char *buf);
+int mp_dvdnav_number_of_subs(stream_t *stream);
+int mp_dvdnav_aid_from_lang(stream_t *stream, unsigned char *language);
+int mp_dvdnav_lang_from_aid(stream_t *stream, int id, unsigned char *buf);
+int mp_dvdnav_sid_from_lang(stream_t *stream, unsigned char *language);
+int mp_dvdnav_lang_from_sid(stream_t *stream, int sid, unsigned char *buf);
 void mp_dvdnav_handle_input(stream_t *stream, int cmd, int *button);
 void mp_dvdnav_update_mouse_pos(stream_t *stream, int32_t x, int32_t y, int* button);
 void mp_dvdnav_get_highlight (stream_t *stream, nav_highlight_t *hl);



More information about the MPlayer-cvslog mailing list