1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ 2 3 /* 4 * Goo 5 * 6 * Copyright (C) 2004 The Free Software Foundation, Inc. 7 * 8 * This program is free software; you can redistribute it and/or modify 9 * it under the terms of the GNU General Public License as published by 10 * the Free Software Foundation; either version 2 of the License, or 11 * (at your option) any later version. 12 * 13 * This program is distributed in the hope that it will be useful, 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 * GNU General Public License for more details. 17 * 18 * You should have received a copy of the GNU General Public License 19 * along with this program; if not, see <http://www.gnu.org/licenses/>. 20 */ 21 22 #ifndef TRACK_INFO_H 23 #define TRACK_INFO_H 24 25 #include <glib.h> 26 #include <glib-object.h> 27 #include <time.h> 28 29 typedef struct { 30 int ref; 31 guint number; 32 gint64 from_time, to_time; 33 gint64 from_sector, to_sector; 34 gint64 time, length, sectors; 35 int min, sec; 36 char *title; 37 char *artist; 38 char *artist_id; 39 } TrackInfo; 40 41 #define GOO_TYPE_TRACK_INFO (track_info_get_type ()) 42 43 GType track_info_get_type (void); 44 TrackInfo * track_info_new (int number, 45 gint64 from_sector, 46 gint64 to_sector); 47 void track_info_ref (TrackInfo *track); 48 void track_info_unref (TrackInfo *track); 49 TrackInfo * track_info_copy (TrackInfo *track); 50 void track_info_set_title (TrackInfo *track, 51 const char *title); 52 void track_info_set_artist (TrackInfo *track, 53 const char *artist, 54 const char *artist_id); 55 void track_info_copy_metadata (TrackInfo *to_info, 56 TrackInfo *from_info); 57 58 GList * track_list_dup (GList *track_list); 59 void track_list_free (GList *track_list); 60 61 62 #endif /* TRACK_INFO_H */ 63