mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-05 15:08:53 +00:00
cleanup. update name and year, queue a redraw for album art
This commit is contained in:
parent
7b3e72ad9d
commit
06bba05143
2 changed files with 6 additions and 11 deletions
|
@ -1,5 +1,5 @@
|
||||||
/* GStreamer media browser
|
/* GStreamer media browser
|
||||||
* Copyright (C) 2010 Stefan Sauer <ensonic@user.sf.net>
|
* Copyright (C) 2010-2012 Stefan Sauer <ensonic@user.sf.net>
|
||||||
*
|
*
|
||||||
* This library is free software; you can redistribute it and/or
|
* This library is free software; you can redistribute it and/or
|
||||||
* modify it under the terms of the GNU Library General Public
|
* modify it under the terms of the GNU Library General Public
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* GStreamer media browser
|
/* GStreamer media browser
|
||||||
* Copyright (C) 2010 Stefan Sauer <ensonic@user.sf.net>
|
* Copyright (C) 2010-2012 Stefan Sauer <ensonic@user.sf.net>
|
||||||
*
|
*
|
||||||
* This library is free software; you can redistribute it and/or
|
* This library is free software; you can redistribute it and/or
|
||||||
* modify it under the terms of the GNU Library General Public
|
* modify it under the terms of the GNU Library General Public
|
||||||
|
@ -628,6 +628,8 @@ public class MediaInfo.Info : VPaned
|
||||||
nb.append_page (table, new Label (@"audio $i"));
|
nb.append_page (table, new Label (@"audio $i"));
|
||||||
}
|
}
|
||||||
nb.show_all();
|
nb.show_all();
|
||||||
|
|
||||||
|
drawing_area.queue_draw();
|
||||||
|
|
||||||
//l = info.get_container_streams ();
|
//l = info.get_container_streams ();
|
||||||
|
|
||||||
|
@ -765,15 +767,7 @@ public class MediaInfo.Info : VPaned
|
||||||
if (str.length > 0)
|
if (str.length > 0)
|
||||||
str += "\n";
|
str += "\n";
|
||||||
|
|
||||||
// TODO: decode images:
|
// decode images, we show them in the drawing area
|
||||||
/*
|
|
||||||
GInputStream is = g_memory_input_stream_new_from_data(GST_BUFFER_DATA(buf),GST_BUFFER_SIZE(buf,NULL);
|
|
||||||
GdkPixbuf pb = gdk_pixbuf_new_from_stream(is, NULL, NULL);
|
|
||||||
g_input_stream_close(is,NULL,NULL);
|
|
||||||
res = gdk_pixbuf_scale_simple(pb, w, h, GDK_INTERP_BILINEAR);
|
|
||||||
*/
|
|
||||||
// - need to figure a way to return them
|
|
||||||
// - where we show them -> in the drawing area
|
|
||||||
v = s.get_value (fn);
|
v = s.get_value (fn);
|
||||||
if (v.holds(typeof(Gst.Buffer))) {
|
if (v.holds(typeof(Gst.Buffer))) {
|
||||||
Gst.Buffer buf = v.get_buffer();
|
Gst.Buffer buf = v.get_buffer();
|
||||||
|
@ -782,6 +776,7 @@ public class MediaInfo.Info : VPaned
|
||||||
try {
|
try {
|
||||||
InputStream is = new MemoryInputStream.from_data (buf.data,null);
|
InputStream is = new MemoryInputStream.from_data (buf.data,null);
|
||||||
album_art = new Gdk.Pixbuf.from_stream (is, null);
|
album_art = new Gdk.Pixbuf.from_stream (is, null);
|
||||||
|
debug("found album art");
|
||||||
is.close(null);
|
is.close(null);
|
||||||
} catch (Error e) {
|
} catch (Error e) {
|
||||||
debug ("Decoding album art failed: %s: %s", e.domain.to_string (), e.message);
|
debug ("Decoding album art failed: %s: %s", e.domain.to_string (), e.message);
|
||||||
|
|
Loading…
Reference in a new issue