Re: [Rhythmbox-devel] monkey-media mixer queue

On Sun, 2003-01-05 at 13:17, Jorn Baayen wrote:
> monkey_media_mixer_set_playing_stream?
Hi, thanks for the suggestion, ive changed the code like so, with the
monkey_mixer_set_playing_stream at the bottom:

void Engine::play_track() {
  GError *error = NULL;
	std::cout << "Playing: " << current_filename << "\n";
	//if monkeymedia is still playing, or paused
	if (monkey_media_mixer_get_state(mixer) !=
	  disconnect_mixer_signal(); // disconnect the mixer signal
	  monkey_media_mixer_set_state (mixer,
	  connect_mixer_signal(); // connect the mixer signal
	  monkey_media_mixer_remove_audio_stream (mixer, stream);
  /* load file from commandline */
  stream = monkey_media_audio_stream_new (current_filename.c_str(),
  if (error != NULL) {
    /* an error occured */
    std::cout << "Failed to create stream: \n" << error->message <<
    g_error_free (error);
    exit (-1);
  /* lego from now on */
  monkey_media_mixer_append_audio_stream (mixer, stream);
	monkey_media_mixer_set_playing_audio_stream (mixer, stream);
  monkey_media_mixer_set_state (mixer,
	gorecki->set_pause_image(); // turn play button to pause

it now plays a song, but when it comes to interrupting the stream to
play a second song it just crashes with:

(gorecki:3975): GStreamer-CRITICAL **: file gstscheduler.c: line 439
(gst_scheduler_interrupt): assertion `GST_IS_SCHEDULER (sched)' failed
gorecki (pid:3975): [E]xit, [H]alt, show [S]tack trace or [P]roceed:

when the actual que ends it is possible to play another song though..

sorry to be a pain

thanks, Rus
Rus Hughes <>

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]