summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuis Medinas <metalgod@gentoo.org>2005-11-09 03:25:02 +0000
committerLuis Medinas <metalgod@gentoo.org>2005-11-09 03:25:02 +0000
commit979778f58218586835db070afd64ad7e01acd9c4 (patch)
treec476e7b9fa0748978b586d2a4dc5a2f0c93ccf3f /media-plugins
parentAdded ~amd64 keyword. Closes bug #111362. (diff)
downloadhistorical-979778f58218586835db070afd64ad7e01acd9c4.tar.gz
historical-979778f58218586835db070afd64ad7e01acd9c4.tar.bz2
historical-979778f58218586835db070afd64ad7e01acd9c4.zip
Added a patch to control window to display when an nsf song is played and change 'Fadeout' option to 'Silence Until Next Song' thanks to <qube99@hotmail.com>.
Package-Manager: portage-2.0.53_rc7
Diffstat (limited to 'media-plugins')
-rw-r--r--media-plugins/xmms-nsf/ChangeLog10
-rw-r--r--media-plugins/xmms-nsf/Manifest19
-rw-r--r--media-plugins/xmms-nsf/files/digest-xmms-nsf-0.0.3-r11
-rw-r--r--media-plugins/xmms-nsf/files/xmms-nsf-0.0.3-about.patch188
-rw-r--r--media-plugins/xmms-nsf/xmms-nsf-0.0.3-r1.ebuild38
5 files changed, 247 insertions, 9 deletions
diff --git a/media-plugins/xmms-nsf/ChangeLog b/media-plugins/xmms-nsf/ChangeLog
index 946e96680991..73ba4fb5748f 100644
--- a/media-plugins/xmms-nsf/ChangeLog
+++ b/media-plugins/xmms-nsf/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for media-plugins/xmms-nsf
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-plugins/xmms-nsf/ChangeLog,v 1.13 2005/09/09 11:30:29 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/xmms-nsf/ChangeLog,v 1.14 2005/11/09 03:25:02 metalgod Exp $
+
+*xmms-nsf-0.0.3-r1 (09 Nov 2005)
+
+ 09 Nov 2005; Luis Medinas <metalgod@gentoo.org>
+ +files/xmms-nsf-0.0.3-about.patch, +xmms-nsf-0.0.3-r1.ebuild:
+ Added a patch to control window to display when an nsf song is played and
+ change 'Fadeout' option to 'Silence Until Next Song' thanks to
+ <qube99@hotmail.com>.
09 Sep 2005; Diego Pettenò <flameeyes@gentoo.org> xmms-nsf-0.0.3.ebuild:
Don't install INSTALL file.
diff --git a/media-plugins/xmms-nsf/Manifest b/media-plugins/xmms-nsf/Manifest
index cfcfa2ac37f2..51374d73f722 100644
--- a/media-plugins/xmms-nsf/Manifest
+++ b/media-plugins/xmms-nsf/Manifest
@@ -1,16 +1,19 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-MD5 ddb98efcfc015a11917bf56dab50482d ChangeLog 1429
-MD5 12c7b44d3171faa9640f7012a9e4c2fd xmms-nsf-0.0.3.ebuild 923
-MD5 a1eaeb2ae801daeb712c90c060e922dc metadata.xml 158
-MD5 8b5a150abf181904c2075418e276dc27 files/xmms-nsf-0.0.3-PIC.patch 1109
+MD5 3b22e65adc88131b61c11d1f18f65dfb ChangeLog 1742
MD5 97224410e57c687737a5624e6ca43faa files/digest-xmms-nsf-0.0.3 66
+MD5 97224410e57c687737a5624e6ca43faa files/digest-xmms-nsf-0.0.3-r1 66
+MD5 8b5a150abf181904c2075418e276dc27 files/xmms-nsf-0.0.3-PIC.patch 1109
+MD5 5a49e69ded2a39ed299ddb5c3c7cb6df files/xmms-nsf-0.0.3-about.patch 6418
MD5 a4b5f9490c67aee61044efdc53229a3d files/xmms-nsf-0.0.3-gcc3.patch 19364
+MD5 a1eaeb2ae801daeb712c90c060e922dc metadata.xml 158
+MD5 f444d088c63ac9914bb47613191c2724 xmms-nsf-0.0.3-r1.ebuild 963
+MD5 12c7b44d3171faa9640f7012a9e4c2fd xmms-nsf-0.0.3.ebuild 923
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.2 (GNU/Linux)
+Version: GnuPG v1.4.1 (GNU/Linux)
-iD8DBQFDIXJsj5H05b2HAEkRAkhkAJ0Vy63Kx+6Zv0V0iXLZ19rTfruTAgCfXAQj
-GvZPk+hFLj1LvfnuCgRHqNM=
-=8tVl
+iD8DBQFDcWzdwUpWvClEHQoRAhQMAJ4lVCo4JPxbGodbnH1RvibQozmFtgCfQloL
+IiqenyDmw1HYC6Hn6ezQA60=
+=0pku
-----END PGP SIGNATURE-----
diff --git a/media-plugins/xmms-nsf/files/digest-xmms-nsf-0.0.3-r1 b/media-plugins/xmms-nsf/files/digest-xmms-nsf-0.0.3-r1
new file mode 100644
index 000000000000..d462c5281aa9
--- /dev/null
+++ b/media-plugins/xmms-nsf/files/digest-xmms-nsf-0.0.3-r1
@@ -0,0 +1 @@
+MD5 45c55a17d81cd82d36d59bdb231777df xmms-nsf-0.0.3.tar.gz 185683
diff --git a/media-plugins/xmms-nsf/files/xmms-nsf-0.0.3-about.patch b/media-plugins/xmms-nsf/files/xmms-nsf-0.0.3-about.patch
new file mode 100644
index 000000000000..6c32699d977e
--- /dev/null
+++ b/media-plugins/xmms-nsf/files/xmms-nsf-0.0.3-about.patch
@@ -0,0 +1,188 @@
+diff -ur xmms-nsf-0.0.3/src/nes/audiosys.c xmms-nsf-0.0.3.about/src/nes/audiosys.c
+--- xmms-nsf-0.0.3/src/nes/audiosys.c 2001-01-06 23:17:57.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/nes/audiosys.c 2005-01-02 20:34:41.767192374 -0500
+@@ -8,8 +8,11 @@
+
+ static NES_AUDIO_HANDLER *nah = 0;
+ static NES_VOLUME_HANDLER *nvh = 0;
+-void NESAudioRender(Int16 *bufp, Uint buflen)
++Uint32 NESAudioRender(Int16 *bufp, Uint buflen)
+ {
++ Int16 x;
++ Uint32 count = 0;
++
+ while (buflen--)
+ {
+ NES_AUDIO_HANDLER *ph;
+@@ -31,9 +34,17 @@
+ else
+ output = accum;
+ output >>= 8;
+- *bufp++ = ((Int32)output) - 0x8000;
++ x = ((Int32)output) - 0x8000;
++ if (abs(x) < 96)
++ count++;
++ else
++ count = 0;
++
++ *bufp++ = x;
+ }
+ }
++
++ return count;
+ }
+
+ void NESVolume(Uint volume)
+diff -ur xmms-nsf-0.0.3/src/nes/audiosys.h xmms-nsf-0.0.3.about/src/nes/audiosys.h
+--- xmms-nsf-0.0.3/src/nes/audiosys.h 2001-01-06 23:17:56.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/nes/audiosys.h 2005-01-02 20:42:51.457112634 -0500
+@@ -21,7 +21,7 @@
+ } NES_VOLUME_HANDLER;
+
+
+-void NESAudioRender(Int16 *bufp, Uint buflen);
++Uint32 NESAudioRender(Int16 *bufp, Uint buflen);
+ void NESAudioHandlerInstall(NES_AUDIO_HANDLER *ph);
+ void NESAudioFrequencySet(Uint freq);
+ Uint NESAudioFrequencyGet(void);
+diff -ur xmms-nsf-0.0.3/src/xmms/callbacks.c xmms-nsf-0.0.3.about/src/xmms/callbacks.c
+--- xmms-nsf-0.0.3/src/xmms/callbacks.c 2000-07-23 05:06:43.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/xmms/callbacks.c 2005-01-02 20:58:29.052175495 -0500
+@@ -219,7 +219,7 @@
+ widget = lookup_widget(GTK_WIDGET(button), "spinbutton1");
+ nsf_cfg.play_time = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget));
+ widget = lookup_widget(GTK_WIDGET(button), "spinbutton2");
+- nsf_cfg.fadeout_time = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget));
++ nsf_cfg.silence_time = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget));
+
+ filename = g_strconcat(g_get_home_dir(), "/.xmms/config", NULL);
+ cfg = xmms_cfg_open_file(filename);
+@@ -228,7 +228,7 @@
+ }
+
+ xmms_cfg_write_int(cfg, "NSF", "play_time",nsf_cfg.play_time);
+- xmms_cfg_write_int(cfg, "NSF", "fadeout_time",nsf_cfg.fadeout_time);
++ xmms_cfg_write_int(cfg, "NSF", "silence_time",nsf_cfg.silence_time);
+ xmms_cfg_write_file(cfg, filename);
+ xmms_cfg_free(cfg);
+ g_free(filename);
+diff -ur xmms-nsf-0.0.3/src/xmms/interface.c xmms-nsf-0.0.3.about/src/xmms/interface.c
+--- xmms-nsf-0.0.3/src/xmms/interface.c 2000-07-23 04:41:14.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/xmms/interface.c 2005-01-02 20:55:32.754086347 -0500
+@@ -106,7 +106,7 @@
+ gtk_label_set_justify (GTK_LABEL (label2), GTK_JUSTIFY_LEFT);
+ gtk_misc_set_alignment (GTK_MISC (label2), 0, 0.5);
+
+- label3 = gtk_label_new ("Fadeout Time:");
++ label3 = gtk_label_new ("Silence Until Next Song:");
+ gtk_widget_ref (label3);
+ gtk_object_set_data_full (GTK_OBJECT (configure), "label3", label3,
+ (GtkDestroyNotify) gtk_widget_unref);
+diff -ur xmms-nsf-0.0.3/src/xmms/nsf.c xmms-nsf-0.0.3.about/src/xmms/nsf.c
+--- xmms-nsf-0.0.3/src/xmms/nsf.c 2001-01-07 00:15:12.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/xmms/nsf.c 2005-01-02 20:58:06.990044841 -0500
+@@ -23,7 +23,8 @@
+
+ #define VERSION "0.0.3"
+ #define PLAYTIME 30
+-#define FADEOUTTIME 5
++#define SILENCETIME 5
++#define FREQ 44100
+
+ #include "nsf.h"
+
+@@ -328,7 +329,7 @@
+ widget = lookup_widget(nsf_configure_win, "spinbutton1");
+ gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget), nsf_cfg.play_time);
+ widget = lookup_widget(nsf_configure_win, "spinbutton2");
+- gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget), nsf_cfg.fadeout_time);
++ gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget), nsf_cfg.silence_time);
+
+ gtk_widget_show(nsf_configure_win);
+ }else{
+@@ -357,7 +358,7 @@
+ nsf_win->dock_window_list = NULL;
+
+ nsf_cfg.play_time = PLAYTIME; /* second */
+- nsf_cfg.fadeout_time = FADEOUTTIME; /* second */
++ nsf_cfg.silence_time = SILENCETIME; /* second */
+ nsf_cfg.player_shaded = FALSE;
+ nsf_cfg.easy_move = FALSE;
+
+@@ -365,7 +366,7 @@
+
+ if ((cfg = xmms_cfg_open_file(filename)) != 0){
+ xmms_cfg_read_int(cfg, "NSF", "play_time", &nsf_cfg.play_time);
+- xmms_cfg_read_int(cfg, "NSF", "fadeout_time", &nsf_cfg.fadeout_time);
++ xmms_cfg_read_int(cfg, "NSF", "silence_time", &nsf_cfg.silence_time);
+ xmms_cfg_free(cfg);
+ }
+ }
+@@ -439,10 +440,11 @@
+ {
+ char data[2048 * 2];
+ int bytes, blk_size, rate;
++ Uint32 c = 0, count = 0;
+
+ //setting NSF
+ NSFSetSongNo(nsf_file->current_song);
+- NESAudioFrequencySet(44100);
++ NESAudioFrequencySet(FREQ);
+ NESReset();
+
+ //16bit/8bit * 1channel * 512 sample = 1024byte
+@@ -460,7 +462,15 @@
+ }
+ if (bytes > 0){
+ //read 1024byte = 512 sample * 2byte
+- NESAudioRender(data, bytes/2);
++ c = NESAudioRender(data, bytes/2);
++ if (c < 512)
++ count = 0;
++ else
++ count += c;
++ if (count > FREQ*nsf_cfg.silence_time) {
++ nsf_file->eos = 1;
++ count = 0;
++ }
+ nsf_ip.add_vis_pcm(nsf_ip.output->written_time(), (nsf_file->bits_per_sample == 16) ? FMT_S16_LE : FMT_U8,
+ nsf_file->channels, bytes, data);
+
+@@ -512,6 +522,9 @@
+ if (!(nsf_file->file = fopen(filename, "rb"))){
+ return;
+ }
++
++ nsf_about();
++
+ fseek(nsf_file->file, 0, SEEK_END);
+ count = ftell(nsf_file->file);
+ fseek(nsf_file->file, 0, SEEK_SET);
+diff -ur xmms-nsf-0.0.3/src/xmms/nsf.h xmms-nsf-0.0.3.about/src/xmms/nsf.h
+--- xmms-nsf-0.0.3/src/xmms/nsf.h 2000-07-23 05:00:35.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/xmms/nsf.h 2005-01-02 20:58:37.563297001 -0500
+@@ -58,7 +58,7 @@
+ typedef struct
+ {
+ gint play_time;
+- gint fadeout_time;
++ gint silence_time;
+ // reserve
+ gint resolution;
+ gint channels;
+diff -ur xmms-nsf-0.0.3/src/xmms/nsflib.h xmms-nsf-0.0.3.about/src/xmms/nsflib.h
+--- xmms-nsf-0.0.3/src/xmms/nsflib.h 2000-07-23 05:05:21.000000000 -0500
++++ xmms-nsf-0.0.3.about/src/xmms/nsflib.h 2005-01-02 20:45:55.481496508 -0500
+@@ -1,10 +1,11 @@
+ typedef signed short Int16;
+ typedef unsigned int Uint;
++typedef unsigned int Uint32;
+ typedef unsigned char Uint8;
+
+ Uint NSFLoad(Uint8 *pData, Uint uSize);
+ void NSFSetSongNo(Uint uSongNo);
+ void NESAudioFrequencySet(Uint freq);
+ void NESReset(void);
+-void NESAudioRender(Int16 *bufp, Uint buflen);
++Uint32 NESAudioRender(Int16 *bufp, Uint buflen);
+ void NESTerminate(void);
diff --git a/media-plugins/xmms-nsf/xmms-nsf-0.0.3-r1.ebuild b/media-plugins/xmms-nsf/xmms-nsf-0.0.3-r1.ebuild
new file mode 100644
index 000000000000..dfa59d62ffe1
--- /dev/null
+++ b/media-plugins/xmms-nsf/xmms-nsf-0.0.3-r1.ebuild
@@ -0,0 +1,38 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-plugins/xmms-nsf/xmms-nsf-0.0.3-r1.ebuild,v 1.1 2005/11/09 03:25:02 metalgod Exp $
+
+inherit eutils gnuconfig autotools libtool
+
+IUSE=""
+
+DESCRIPTION="An xmms input-plugin for NSF-files (the nintendo 8-bit soundfiles) that uses source from NEZamp."
+HOMEPAGE="http://www.xmms.org/"
+SRC_URI="http://optronic.sourceforge.net/files/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+#-sparc: 0.0.3: Plays, but not completely... misses notes
+KEYWORDS="~x86 -sparc ~amd64 -ppc"
+
+DEPEND="media-sound/xmms
+ =x11-libs/gtk+-1.2*"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ epatch ${FILESDIR}/${P}-about.patch
+ epatch ${FILESDIR}/${P}-gcc3.patch
+ epatch ${FILESDIR}/${P}-PIC.patch
+
+ gnuconfig_update
+
+ export WANT_AUTOMAKE=1.4
+ eautomake
+ elibtoolize
+}
+
+src_install() {
+ make DESTDIR=${D} install || die
+ dodoc AUTHORS ChangeLog NEWS README
+}