annotate Plugins/Input/aac/src/tagging_mp4.c @ 1459:705d4c089fce trunk

[svn] Fix postal code.
author chainsaw
date Wed, 02 Aug 2006 16:00:13 -0700
parents f12d7e208b43
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
1 /*
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
2 * Audacious -- Cross-platform Multimedia Player
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
3 * Copyright (c) 2005-2006 William Pitcock <nenolod@nenolod.net>
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
4 *
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
5 * This program is free software; you can redistribute it and/or modify
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
6 * it under the terms of the GNU General Public License as published by
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
7 * the Free Software Foundation; either version 2 of the License, or
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
8 * (at your option) any later version.
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
9 *
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
10 * This program is distributed in the hope that it will be useful,
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
13 * GNU General Public License for more details.
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
14 *
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
16 * along with this program; if not, write to the Free Software
1459
705d4c089fce [svn] Fix postal code.
chainsaw
parents: 1458
diff changeset
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
18 */
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
19
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
20 #include <glib.h>
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
21 #include <string.h>
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
22 #include <unistd.h>
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
23 #include <stdlib.h>
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
24
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
25 #include "tagging.h"
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
26
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
27 gchar *audmp4_get_artist(mp4ff_t *file)
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
28 {
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
29 gchar *value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
30
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
31 mp4ff_meta_get_artist(file, &value);
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
32
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
33 return value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
34 }
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
35
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
36 gchar *audmp4_get_title(mp4ff_t *file)
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
37 {
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
38 gchar *value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
39
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
40 mp4ff_meta_get_title(file, &value);
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
41
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
42 return value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
43 }
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
44
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
45 gchar *audmp4_get_album(mp4ff_t *file)
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
46 {
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
47 gchar *value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
48
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
49 mp4ff_meta_get_album(file, &value);
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
50
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
51 return value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
52 }
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
53
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
54 gchar *audmp4_get_genre(mp4ff_t *file)
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
55 {
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
56 gchar *value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
57
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
58 mp4ff_meta_get_genre(file, &value);
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
59
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
60 return value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
61 }
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
62
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
63 gint audmp4_get_year(mp4ff_t *file)
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
64 {
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
65 gchar *value;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
66
1029
54dd4df67688 [svn] - src/tagging_mp4.c, fileinfo.c, libmp4.c: Finish conversion to internal container code.
nenolod
parents: 341
diff changeset
67 mp4ff_meta_get_date(file, &value);
341
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
68
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
69 if (!value)
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
70 return 0;
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
71
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
72 return atoi(value);
46271e2c9622 [svn] Initial tagging_mp4.c code. Still need to add a class for aac tagging information (ID3)
nenolod
parents:
diff changeset
73 }