Posts: 123
Joined: Mar 2015
Reputation:
3
Is it possible to fetch movie information from a media file (such as subtitles and audio streams), before actually invoking the player?
I think it would be interesting to display such information before launching the player, in the VideoNav or DialogVideoInfo windows.
Anyone knows if there is code available for this? I am talking about C++ here, I know (I think...) it is not possible to do this from a skin.
Posts: 6,252
Joined: Jun 2009
Reputation:
115
da-anda
Team-Kodi Member
Posts: 6,252
you'd need to scan it into your library, or if the file resides in a folder that's within a configured source, opening the movie info view will automatically scrape stuff and extract stream details.
Posts: 123
Joined: Mar 2015
Reputation:
3
Which one do you call the "movie info view"?? Are you referring to DialogVideoInfo ??
Posts: 6,252
Joined: Jun 2009
Reputation:
115
da-anda
Team-Kodi Member
Posts: 6,252
the one that comes up when pressing "i" on the keyboard, but yes, I think it's DialogVideoInfo. Opening this dialog will trigger a scrape of that file, but as said, only if it's within a correctly configured source (so with media type set to movies, desired scraper selected etc).
Posts: 123
Joined: Mar 2015
Reputation:
3
Yes that's DialogVideoInfo. You are correct, it will fetch information about the movie, but I realize my question was not precise. I am specifically looking for the available audio streams, and available subtitles. This information is contained in the source file, and (after looking at the code) i don't think it is actually available until the player starts.
Posts: 15,263
Joined: Jan 2009
Reputation:
727
ronie
Team-Kodi Member
Posts: 15,263
if the question is, as i understand it, how to get *all* audio stream and subtitles,
then yes, that info is only available during playback.
when you scan items to the library, only one audio stream and subtitle language will be stored in the database (afaik).
Posts: 3,077
Joined: Jun 2009
All streams are now stored in Database, info about audio streams are just a little lower :
- "channels", "codec", "bitrate" are not available but counts and languages are
Starting from Kodi it seems that scraping a source is not enough to trigger this data gathering you need to browse it from GUI so that it start, this is a regression from before but seems wanted if I remember from other discussions.