mirror of
https://github.com/owntone/owntone-server.git
synced 2025-04-16 09:08:04 -04:00
Split TV show tags out of the generic md_map
This commit is contained in:
parent
27a095b606
commit
04e8f5cfd6
@ -79,6 +79,11 @@ static struct metadata_map md_map_generic[] =
|
|||||||
{ "year", 1, mfi_offsetof(year) },
|
{ "year", 1, mfi_offsetof(year) },
|
||||||
{ "date", 1, mfi_offsetof(year) },
|
{ "date", 1, mfi_offsetof(year) },
|
||||||
|
|
||||||
|
{ NULL, 0, 0 }
|
||||||
|
};
|
||||||
|
|
||||||
|
static struct metadata_map md_map_tv[] =
|
||||||
|
{
|
||||||
{ "stik", 1, mfi_offsetof(media_kind) },
|
{ "stik", 1, mfi_offsetof(media_kind) },
|
||||||
{ "show", 0, mfi_offsetof(tv_series_name) },
|
{ "show", 0, mfi_offsetof(tv_series_name) },
|
||||||
{ "episode_id", 0, mfi_offsetof(tv_episode_num_str) },
|
{ "episode_id", 0, mfi_offsetof(tv_episode_num_str) },
|
||||||
@ -361,6 +366,8 @@ scan_metadata_ffmpeg(char *file, struct media_file_info *mfi)
|
|||||||
mfi->type = strdup("m4v");
|
mfi->type = strdup("m4v");
|
||||||
mfi->codectype = strdup("mp4v");
|
mfi->codectype = strdup("mp4v");
|
||||||
mfi->description = strdup("MPEG-4 video file");
|
mfi->description = strdup("MPEG-4 video file");
|
||||||
|
|
||||||
|
extra_md_map = md_map_tv;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CODEC_ID_MP3:
|
case CODEC_ID_MP3:
|
||||||
@ -426,7 +433,10 @@ scan_metadata_ffmpeg(char *file, struct media_file_info *mfi)
|
|||||||
mfi->type = strdup("unkn");
|
mfi->type = strdup("unkn");
|
||||||
mfi->codectype = strdup("unkn");
|
mfi->codectype = strdup("unkn");
|
||||||
if (mfi->has_video)
|
if (mfi->has_video)
|
||||||
|
{
|
||||||
mfi->description = strdup("Unknown video file format");
|
mfi->description = strdup("Unknown video file format");
|
||||||
|
extra_md_map = md_map_tv;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
mfi->description = strdup("Unknown audio file format");
|
mfi->description = strdup("Unknown audio file format");
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user