Author: fejj
Date: 2008-01-17 17:28:42 -0500 (Thu, 17 Jan 2008)
New Revision: 93213
Modified:
trunk/moon/src/mplayer2.cpp
trunk/moon/src/pipeline.h
Log:
removed some printf's and rearranged pipeline.h a bit
Modified: trunk/moon/src/mplayer2.cpp
===================================================================
--- trunk/moon/src/mplayer2.cpp 2008-01-17 22:10:33 UTC (rev 93212)
+++ trunk/moon/src/mplayer2.cpp 2008-01-17 22:28:42 UTC (rev 93213)
@@ -1151,7 +1151,6 @@
}
if ((frame_pts = audio_play (audio, true, ufds, ndfs)) > 0) {
- printf ("played an audio frame\n");
// calculated pts
//printf ("frame_pts = %llu\n", frame_pts);
pthread_mutex_lock (&mplayer->target_pts_lock);
@@ -1182,8 +1181,6 @@
} else if (!pkt) {
// need to either wait for another
// audio packet to be queued
- //audio->queue->Wait ();
- printf ("waiting for audio packet\n");
}
if (pkt != NULL) {
@@ -1210,7 +1207,7 @@
}
}
- printf ("audio_loop (): exited.\n");
+ //printf ("audio_loop (): exited.\n");
if (pkt != NULL)
delete pkt;
Modified: trunk/moon/src/pipeline.h
===================================================================
--- trunk/moon/src/pipeline.h 2008-01-17 22:10:33 UTC (rev 93212)
+++ trunk/moon/src/pipeline.h 2008-01-17 22:28:42 UTC (rev 93213)
@@ -198,6 +198,35 @@
};
class Media {
+ static ConverterInfo *registered_converters;
+ static DemuxerInfo *registered_demuxers;
+ static DecoderInfo *registered_decoders;
+
+ class Node : public List::Node {
+ public:
+ MediaFrame *frame;
+ uint16_t states;
+ };
+
+ List *queued_requests;
+ pthread_t queue_thread;
+ pthread_cond_t queue_condition;
+ pthread_mutex_t queue_mutex;
+ MediaClosure *queue_closure;
+
+ char *file_or_url;
+ IMediaSource *source;
+ IMediaDemuxer *demuxer;
+ List *markers;
+ uint64_t start_time;
+
+ // Called on another thread, loops the queue of requested frames
+ // and calls GetNextFrame and FrameReadCallback.
+ // If there are any requests for audio frames in the queue
+ // they are always (and all of them) satisfied before any video
frame request.
+ void FrameReaderLoop ();
+ static void *FrameReaderLoop (void *data);
+
public:
Media ();
~Media ();
@@ -265,43 +294,12 @@
static void Initialize ();
static void Shutdown ();
-
-private:
- static DemuxerInfo *registered_demuxers;
- static DecoderInfo *registered_decoders;
- static ConverterInfo *registered_converters;
-
-private:
- // Called on another thread, loops the queue of requested frames
- // and calls GetNextFrame and FrameReadCallback.
- // If there are any requests for audio frames in the queue
- // they are always (and all of them) satisfied before any video
frame request.
- void FrameReaderLoop ();
- static void *FrameReaderLoop (void *data);
-
- IMediaSource *source;
- IMediaDemuxer *demuxer;
- List *markers;
- char *file_or_url;
- uint64_t start_time;
-
- List *queued_requests;
- pthread_t queue_thread;
- pthread_cond_t queue_condition;
- pthread_mutex_t queue_mutex;
- MediaClosure *queue_closure;
-
- class Node : public List::Node {
- public:
- MediaFrame *frame;
- uint16_t states;
- };
};
class MediaFrame {
public:
- ~MediaFrame ();
MediaFrame (IMediaStream *stream);
+ ~MediaFrame ();
void AddState (uint16_t state) { this->state |= state; } // There's no
way of "going back" to an earlier state
bool IsDecoded () { return (state & FRAME_DECODED) == FRAME_DECODED; }
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches