diff options
author | waker <wakeroid@gmail.com> | 2011-03-24 21:30:11 +0100 |
---|---|---|
committer | waker <wakeroid@gmail.com> | 2011-03-24 21:30:11 +0100 |
commit | fd04c7a395f4ac26942222e29e2dd9a8901bff41 (patch) | |
tree | 0ed33d33f0171603c7f6503b52f5512770e59fcd /streamer.c | |
parent | 2278425be18b7600c055e54e5777b44858e1af4e (diff) |
got rid of filetype field in playitem structure
Diffstat (limited to 'streamer.c')
-rw-r--r-- | streamer.c | 8 |
1 files changed, 3 insertions, 5 deletions
@@ -599,7 +599,8 @@ streamer_set_current (playItem_t *it) { plug_trigger_event_trackinfochanged (from); } const char *decoder_id = pl_find_meta (it, ":DECODER"); - if (!decoder_id && it->filetype && !strcmp (it->filetype, "content")) { + const char *filetype = pl_find_meta (it, ":FILETYPE"); + if (!decoder_id && filetype && !strcmp (filetype, "content")) { // try to get content-type mutex_lock (decodemutex); trace ("\033[0;34mopening file %s\033[37;0m\n", pl_find_meta (it, ":URI")); @@ -638,7 +639,7 @@ streamer_set_current (playItem_t *it) { if (!strcmp (decoders[i]->plugin.id, plug)) { pl_replace_meta (it, ":DECODER", decoders[i]->plugin.id); decoder_id = decoders[i]->plugin.id; - it->filetype = decoders[i]->filetypes[0]; + pl_replace_meta (it, ":FILETYPE", decoders[i]->filetypes[0]); trace ("\033[0;34mfound plugin %s\033[37;0m\n", plug); } } @@ -1641,9 +1642,6 @@ streamer_read (char *bytes, int size) { playpos += (float)sz/output->fmt.samplerate/((output->fmt.bps>>3)*output->fmt.channels) * dsp_ratio; playing_track->playtime += (float)sz/output->fmt.samplerate/((output->fmt.bps>>3)*output->fmt.channels); if (playlist_track) { - playing_track->filetype = playlist_track->filetype; - } - if (playlist_track) { playlist_track->playtime = playing_track->playtime; } if (bytes_until_next_song > 0) { |