1 /* EasyTAG - tag editor for audio files 2 * Copyright (C) 2014 David King <amigadave@amigadave.com> 3 * 4 * This program is free software; you can redistribute it and/or modify it 5 * under the terms of the GNU General Public License as published by the Free 6 * Software Foundation; either version 2 of the License, or (at your option) 7 * any later version. 8 * 9 * This program is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12 * more details. 13 * 14 * You should have received a copy of the GNU General Public License along with 15 * this program; if not, write to the Free Software Foundation, Inc., 51 16 * Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 */ 18 19 #ifndef ET_CORE_TYPES_H_ 20 #define ET_CORE_TYPES_H_ 21 22 #include <glib.h> 23 24 G_BEGIN_DECLS 25 26 /* 27 * ET_File_Type: 28 * @MP2_FILE: MPEG audio Layer 2: .mp2 (.mpg) (.mpga) 29 * @MP3_FILE: MPEG audio Layer 3: .mp3 (.mpg) (.mpga) 30 * @MP4_FILE: MPEG audio Layer 4 / AAC: .mp4 (.m4a) (.m4p) (.m4v) 31 * @OGG_FILE: Ogg Vorbis audio: .ogg (.ogm) 32 * @FLAC_FILE: FLAC (lossless): .flac .fla 33 * @MPC_FILE: MusePack: .mpc .mp+ .mpp 34 * @MAC_FILE: Monkey's Audio (lossless): .ape (.mac) 35 * @SPEEX_FILE: Speech audio files: .spx 36 * @OFR_FILE: OptimFROG (lossless): .ofr .ofs 37 * @WAVPACK_FILE: Wavpack (lossless): .wv 38 * @OPUS_FILE: Ogg Opus audio: .opus 39 * @UNKNOWN_FILE: not a recognized file 40 * Types of files 41 */ 42 typedef enum 43 { /* (.ext) is not so popular. */ 44 MP2_FILE = 0, 45 MP3_FILE, 46 MP4_FILE, 47 OGG_FILE, 48 FLAC_FILE, 49 MPC_FILE, 50 MAC_FILE, 51 SPEEX_FILE, 52 OFR_FILE, 53 WAVPACK_FILE, 54 OPUS_FILE, 55 UNKNOWN_FILE 56 } ET_File_Type; 57 58 /* 59 * Types of tags 60 */ 61 typedef enum 62 { 63 ID3_TAG = 0, 64 OGG_TAG, 65 APE_TAG, 66 FLAC_TAG, 67 MP4_TAG, 68 WAVPACK_TAG, 69 OPUS_TAG, 70 UNKNOWN_TAG 71 } ET_Tag_Type; 72 73 /* 74 * EtFileHeaderFields: 75 * @description: a description of the file type, such as MP3 File 76 * @version_label: the label for the encoder version, such as MPEG 77 * @version: the encoder version (such as 2, Layer III) 78 * @bitrate: the bitrate of the file (not the bit depth of the samples) 79 * @samplerate: the sample rate of the primary audio track, generally in Hz 80 * @mode_label: the label for the audio mode, for example Mode 81 * @mode: the audio mode (stereo, mono, and so on) 82 * @size: the size of the audio file 83 * @duration: the length of the primary audio track 84 * 85 * UI-visible strings, populated by the tagging support code to be displayed in 86 * the EtFileArea. 87 */ 88 typedef struct 89 { 90 /*< public >*/ 91 gchar *description; 92 gchar *version_label; 93 gchar *version; 94 gchar *bitrate; 95 gchar *samplerate; 96 gchar *mode_label; 97 gchar *mode; 98 gchar *size; 99 gchar *duration; 100 } EtFileHeaderFields; 101 102 G_END_DECLS 103 104 #endif /* ET_TYPES_H_ */ 105