annotate src/xs_stil.c @ 103:fe83646e6baa

Changed plrFillBuffer()-functions to return actual number of samples computed. Rudimentary changes for return of fileinfo window. Minor tweaks for STILdb.
author Matti Hamalainen <ccr@tnsp.org>
date Sun, 11 Jan 2004 17:42:00 +0000
parents 4614f58ab169
children 578b71b62eeb
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
1 /*
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
2 XMMS-SID - SIDPlay input plugin for X MultiMedia System (XMMS)
1
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
3
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
4 STIL-database handling functions
1
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
5
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
6 Written by Matti "ccr" Hamalainen <ccr@tnsp.org>
1
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
7
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
8 This program is free software; you can redistribute it and/or modify
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
9 it under the terms of the GNU General Public License as published by
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
10 the Free Software Foundation; either version 2 of the License, or
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
11 (at your option) any later version.
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
12
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
13 This program is distributed in the hope that it will be useful,
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
16 GNU General Public License for more details.
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
17
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
18 You should have received a copy of the GNU General Public License
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
19 along with this program; if not, write to the Free Software
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
20 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
21 */
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
22 #include "xs_stil.h"
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
23 #include "xs_support.h"
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
24 #include "xs_config.h"
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
25 #include <stdlib.h>
1
183e7cbc1036 Initial revision
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
26 #include <stdio.h>
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
27 #include <ctype.h>
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
28 #include <string.h>
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
29
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
30
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
31 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
32 * Pointer to database in memory
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
33 */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
34 static t_xs_stil_node *xs_stildb = NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
35 static t_xs_stil_node **xs_stildbi = NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
36 static gint xs_stildbn = 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
37
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
38
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
39 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
40 * Hash-database handling functions
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
41 */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
42 t_xs_stil_node *xs_stildb_node_new(void)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
43 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
44 t_xs_stil_node *pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
45
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
46 /* Allocate memory for new node */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
47 pResult = (t_xs_stil_node *) g_malloc0(sizeof(t_xs_stil_node));
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
48 if (!pResult) return NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
49
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
50 return pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
51 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
52
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
53
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
54 void xs_stildb_node_free(t_xs_stil_node *pNode)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
55 {
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
56 gint i;
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
57
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
58 if (pNode)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
59 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
60 for (i = 0; i < pNode->nsubTunes; i++)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
61 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
62 g_free(pNode->subTune[i].pName);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
63 g_free(pNode->subTune[i].pTitle);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
64 g_free(pNode->subTune[i].pArtist);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
65 g_free(pNode->subTune[i].pComment);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
66 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
67
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
68 g_free(pNode->pcFilename);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
69 g_free(pNode);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
70 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
71 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
72
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
73
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
74 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
75 * Insert given node to db linked list
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
76 */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
77 #define LPREV (pNode->pPrev)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
78 #define LTHIS (pNode)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
79 #define LNEXT (pNode->pNext)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
80
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
81 void xs_stildb_node_insert(t_xs_stil_node *pNode)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
82 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
83 if (xs_stildb)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
84 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
85 /* The first node's pPrev points to last node */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
86 LPREV = xs_stildb->pPrev; /* New node's prev = Previous last node */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
87 xs_stildb->pPrev->pNext = pNode; /* Previous last node's next = New node */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
88 xs_stildb->pPrev = pNode; /* New last node = New node */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
89 LNEXT = NULL; /* But next is NULL! */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
90 } else {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
91 xs_stildb = pNode; /* First node ... */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
92 LPREV = pNode; /* ... it's also last */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
93 LNEXT = NULL; /* But next is NULL! */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
94 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
95 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
96
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
97
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
98 /*
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
99 * Get STIL information from database
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
100 */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
101 t_xs_stil_node * xs_stildb_get(gchar *pcFilename)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
102 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
103 gint iStartNode, iEndNode, iQNode, r, i;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
104 gboolean iFound;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
105 t_xs_stil_node *pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
106
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
107 /* Check the database pointers */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
108 if (!xs_stildb || !xs_stildbi)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
109 return NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
110
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
111 /* Look-up via index using binary search */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
112 pResult = NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
113 iStartNode = 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
114 iEndNode = (xs_stildbn - 1);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
115 iQNode = (iEndNode / 2);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
116 iFound = FALSE;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
117
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
118 while ((!iFound) && ((iEndNode - iStartNode) > 128))
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
119 {
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
120 r = strcmp(pcFilename, xs_stildbi[iQNode]->pcFilename);
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
121 if (r < 0)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
122 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
123 /* Hash was in the <- LEFT side */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
124 iEndNode = iQNode;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
125 iQNode = iStartNode + ((iEndNode - iStartNode) / 2);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
126 } else
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
127 if (r > 0)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
128 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
129 /* Hash was in the RIGHT -> side */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
130 iStartNode = iQNode;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
131 iQNode = iStartNode + ((iEndNode - iStartNode) / 2);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
132 } else
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
133 iFound = TRUE;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
134 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
135
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
136 /* If not found already */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
137 if (!iFound)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
138 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
139 /* Search the are linearly */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
140 iFound = FALSE;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
141 i = iStartNode;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
142 while ((i <= iEndNode) && (!iFound))
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
143 {
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
144 if (strcmp(pcFilename, xs_stildbi[iQNode]->pcFilename) == 0)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
145 iFound = TRUE;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
146 else
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
147 i++;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
148 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
149
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
150 /* Check the result */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
151 if (iFound)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
152 pResult = xs_stildbi[i];
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
153
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
154 } else {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
155 /* Found via binary search */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
156 pResult = xs_stildbi[iQNode];
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
157 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
158
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
159
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
160 return pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
161 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
162
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
163
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
164 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
165 * Read database to memory
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
166 */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
167 gint xs_stildb_read(gchar *dbFilename)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
168 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
169 FILE *inFile;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
170 gchar inLine[XS_BUFSIZE];
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
171 guint lineNum, linePos;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
172 gboolean iOK;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
173 t_xs_stil_node *tmpNode;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
174
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
175 /* Try to open the file */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
176 if ((inFile = fopen(dbFilename, "ra")) == NULL)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
177 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
178 XSERR("Could not open STILDB '%s'\n", dbFilename);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
179 return -1;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
180 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
181
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
182 /* Read and parse the data */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
183 lineNum = 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
184
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
185 while (!feof(inFile))
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
186 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
187 fgets(inLine, sizeof(inLine), inFile);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
188 lineNum++;
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
189
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
190 #if 0
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
191 switch (inLine[0]) {
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
192 case '/':
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
193 /* A new entry */
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
194
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
195 isEntry = TRUE;
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
196 break;
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
197
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
198 case '(':
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
199 subEntry =
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
200 break;
101
Matti Hamalainen <ccr@tnsp.org>
parents: 99
diff changeset
201
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
202 default:
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
203 /* End of entry */
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
204 isEntry = FALSE;
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
205 break;
101
Matti Hamalainen <ccr@tnsp.org>
parents: 99
diff changeset
206
103
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
207 }
fe83646e6baa Changed plrFillBuffer()-functions to return actual number of samples computed.
Matti Hamalainen <ccr@tnsp.org>
parents: 101
diff changeset
208 #endif
101
Matti Hamalainen <ccr@tnsp.org>
parents: 99
diff changeset
209
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
210 } /* while */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
211
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
212 /* Close the file */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
213 fclose(inFile);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
214 return 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
215 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
216
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
217
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
218 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
219 * Compare two nodes' hashes
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
220 */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
221 gint xs_stildb_cmp(const void *pNode1, const void *pNode2)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
222 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
223 /* We assume here that we never ever get NULL-pointers or similar */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
224 return strcmp((*(t_xs_stil_node **) pNode1)->pcFilename,
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
225 (*(t_xs_stil_node **) pNode2)->pcFilename);
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
226 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
227
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
228
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
229 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
230 * Initialize the song-length system
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
231 */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
232 gint xs_stil_init(void)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
233 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
234 t_xs_stil_node *pCurr;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
235 gint i;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
236
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
237 XSDEBUG("stil_init()\n");
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
238
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
239 /* Read the database */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
240 if (!xs_cfg.stilDBPath)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
241 return -10;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
242
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
243 if (xs_stildb_read(xs_cfg.stilDBPath) < 0)
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
244 return -9;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
245
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
246 XSDEBUG("indexing...\n");
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
247
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
248 /* Get size of db */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
249 pCurr = xs_stildb;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
250 xs_stildbn = 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
251 while (pCurr)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
252 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
253 xs_stildbn++;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
254 pCurr = pCurr->pNext;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
255 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
256
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
257 /* Check number of nodes */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
258 if (xs_stildbn > 0)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
259 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
260 /* Allocate memory for index-table */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
261 xs_stildbi = (t_xs_stil_node **) g_malloc(sizeof(t_xs_stil_node *) * xs_stildbn);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
262 if (!xs_stildbi) return -6;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
263
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
264 /* Get node-pointers to table */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
265 i = 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
266 pCurr = xs_stildb;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
267 while (pCurr)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
268 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
269 xs_stildbi[i++] = pCurr;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
270 pCurr = pCurr->pNext;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
271 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
272
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
273 /* Sort the indexes */
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
274 qsort(xs_stildbi, xs_stildbn, sizeof(t_xs_stil_node *), xs_stildb_cmp);
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
275 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
276
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
277 /* OK */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
278 XSDEBUG("init ok.\n");
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
279 return 0;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
280 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
281
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
282
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
283 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
284 * Close song-length system
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
285 */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
286 void xs_stil_close(void)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
287 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
288 t_xs_stil_node *pCurr, *pNext;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
289
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
290 /* Free the memory allocated for database */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
291 XSDEBUG("stildb_close()\n");
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
292 pCurr = xs_stildb;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
293 while (pCurr)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
294 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
295 pNext = pCurr->pNext;
99
2bc56809ec0b STIL-support fixes, variable renaming
Matti Hamalainen <ccr@tnsp.org>
parents: 94
diff changeset
296 xs_stildb_node_free(pCurr);
94
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
297 pCurr = pNext;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
298 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
299
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
300 xs_stildb = NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
301
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
302 /* Free memory allocated for indexes */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
303 if (xs_stildbi)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
304 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
305 g_free(xs_stildbi);
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
306 xs_stildbi = NULL;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
307 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
308 }
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
309
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
310
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
311 /*
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
312 * Get STIL information
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
313 */
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
314 t_xs_stil_node * xs_stil_get(gchar *pcFilename)
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
315 {
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
316 t_xs_stil_node *pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
317
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
318 return pResult;
086681f70910 Start of re-write of STIL-support
Matti Hamalainen <ccr@tnsp.org>
parents: 62
diff changeset
319 }