changeset 756:8299288df6d2

Rename internal structures.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 05 Nov 2012 18:53:20 +0200
parents 762ef85ead1a
children 9c135d421676
files src/xs_sidplay1.cc src/xs_sidplay2.cc
diffstat 2 files changed, 31 insertions(+), 31 deletions(-) [+]
line wrap: on
line diff
--- a/src/xs_sidplay1.cc	Mon Nov 05 18:52:43 2012 +0200
+++ b/src/xs_sidplay1.cc	Mon Nov 05 18:53:20 2012 +0200
@@ -43,7 +43,7 @@
     sidTune *currTune;
     guint8 *buf;
     size_t bufSize;
-} xs_sidplay1_t;
+} XSSIDPlay1;
 
 
 /* We need to 'export' all this pseudo-C++ crap */
@@ -56,7 +56,7 @@
 #define TFUNCTION2  xs_sidplay1_updateinfo
 #define TTUNEINFO   sidTuneInfo
 #define TTUNE       sidTune
-#define TENGINE     xs_sidplay1_t
+#define TENGINE     XSSIDPlay1
 #include "xs_sidplay.h"
 
 
@@ -83,11 +83,11 @@
 gboolean xs_sidplay1_init(XSEngineState * state)
 {
     gint tmpFreq;
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
 
     /* Allocate internal structures */
-    engine = (xs_sidplay1_t *) g_malloc0(sizeof(xs_sidplay1_t));
+    engine = (XSSIDPlay1 *) g_malloc0(sizeof(XSSIDPlay1));
     if (!engine) return FALSE;
 
     /* Initialize engine */
@@ -246,10 +246,10 @@
  */
 void xs_sidplay1_close(XSEngineState * state)
 {
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
 
-    engine = (xs_sidplay1_t *) state->internal;
+    engine = (XSSIDPlay1 *) state->internal;
 
     /* Free internals */
     if (engine->currEng) {
@@ -273,10 +273,10 @@
  */
 gboolean xs_sidplay1_initsong(XSEngineState * state)
 {
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
 
-    engine = (xs_sidplay1_t *) state->internal;
+    engine = (XSSIDPlay1 *) state->internal;
     if (!engine) return FALSE;
 
     if (!engine->currTune) {
@@ -299,10 +299,10 @@
  */
 guint xs_sidplay1_fillbuffer(XSEngineState * state, gchar * audioBuffer, guint audioBufSize)
 {
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
 
-    engine = (xs_sidplay1_t *) state->internal;
+    engine = (XSSIDPlay1 *) state->internal;
     if (!engine) return 0;
 
     sidEmuFillBuffer(*engine->currEng, *engine->currTune, audioBuffer, audioBufSize);
@@ -315,11 +315,11 @@
  */
 gboolean xs_sidplay1_load(XSEngineState * state, gchar * filename)
 {
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
     state->isInitialized = FALSE;
 
-    engine = (xs_sidplay1_t *) state->internal;
+    engine = (XSSIDPlay1 *) state->internal;
     if (!engine) return FALSE;
 
     /* Try to get the tune */
@@ -339,10 +339,10 @@
  */
 void xs_sidplay1_delete(XSEngineState * state)
 {
-    xs_sidplay1_t *engine;
+    XSSIDPlay1 *engine;
     assert(state);
 
-    engine = (xs_sidplay1_t *) state->internal;
+    engine = (XSSIDPlay1 *) state->internal;
     if (!engine) return;
     
     g_free(engine->buf);
--- a/src/xs_sidplay2.cc	Mon Nov 05 18:52:43 2012 +0200
+++ b/src/xs_sidplay2.cc	Mon Nov 05 18:53:20 2012 +0200
@@ -37,7 +37,7 @@
 #  include <sidplay/sidlazyiptr.h>
 #endif
 
-class xs_sidplay2_t {
+class XSSIDPlay2 {
 public:
 #ifdef HAVE_SIDPLAY2_FP
     sidplay2 *currEng;
@@ -51,8 +51,8 @@
     guint8 *buf;
     size_t bufSize;
     
-    xs_sidplay2_t(void);
-    virtual ~xs_sidplay2_t(void) { ; }
+    XSSIDPlay2(void);
+    virtual ~XSSIDPlay2(void) { ; }
 };
 
 
@@ -73,7 +73,7 @@
 #endif
 
 
-xs_sidplay2_t::xs_sidplay2_t(void)
+XSSIDPlay2::XSSIDPlay2(void)
 #ifdef HAVE_SIDPLAY2_FP
 :currEng(NULL)
 #else
@@ -97,7 +97,7 @@
 #define TFUNCTION2  xs_sidplay2_updateinfo
 #define TTUNEINFO   SidTuneInfo
 #define TTUNE       SidTune
-#define TENGINE     xs_sidplay2_t
+#define TENGINE     XSSIDPlay2
 #include "xs_sidplay.h"
 
 
@@ -124,13 +124,13 @@
 gboolean xs_sidplay2_init(XSEngineState * state)
 {
     gint i;
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     sid_filter_t tmpFilter;
     xs_sid_filter_t *f;
     assert(state);
 
     /* Allocate internal structures */
-    engine = new xs_sidplay2_t();
+    engine = new XSSIDPlay2();
     state->internal = engine;
     if (!engine) return FALSE;
 
@@ -432,10 +432,10 @@
  */
 void xs_sidplay2_close(XSEngineState * state)
 {
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     assert(state);
 
-    engine = (xs_sidplay2_t *) state->internal;
+    engine = (XSSIDPlay2 *) state->internal;
 
     /* Free internals */
     if (engine->currBuilder) {
@@ -468,10 +468,10 @@
  */
 gboolean xs_sidplay2_initsong(XSEngineState * state)
 {
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     assert(state);
 
-    engine = (xs_sidplay2_t *) state->internal;
+    engine = (XSSIDPlay2 *) state->internal;
     if (!engine) return FALSE;
 
     if (!engine->currTune->selectSong(state->currSong)) {
@@ -494,10 +494,10 @@
  */
 guint xs_sidplay2_fillbuffer(XSEngineState * state, gchar * audioBuffer, guint audioBufSize)
 {
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     assert(state);
 
-    engine = (xs_sidplay2_t *) state->internal;
+    engine = (XSSIDPlay2 *) state->internal;
     if (!engine) return 0;
 
     return engine->currEng->play((short *) audioBuffer, audioBufSize / sizeof(short));
@@ -508,11 +508,11 @@
  */
 gboolean xs_sidplay2_load(XSEngineState * state, gchar * pcFilename)
 {
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     assert(state);
     state->isInitialized = FALSE;
 
-    engine = (xs_sidplay2_t *) state->internal;
+    engine = (XSSIDPlay2 *) state->internal;
     if (!engine) return FALSE;
 
     /* Try to get the tune */
@@ -532,10 +532,10 @@
  */
 void xs_sidplay2_delete(XSEngineState * state)
 {
-    xs_sidplay2_t *engine;
+    XSSIDPlay2 *engine;
     assert(state);
 
-    engine = (xs_sidplay2_t *) state->internal;
+    engine = (XSSIDPlay2 *) state->internal;
     if (!engine) return;
     
     g_free(engine->buf);