[Music Videos] Don't show allup in the list
#1
I have a problem.
I just added a bunch of properly tagged mp4 music videos as music videos and for some reason only a few are actually shown in the library.
Under Files I can find them all though.
It seems like XBMC tries to look my files up and doesn't find the title etc on the Internet and thus they won't be displayed in the library.

How can I fix this? It's also not bnecessary to rwead the data from the web, it's all in the files (Cover, title, artist, tracknumber, genre).

Best regards,
Forivon
Reply
#2
Music videos work like all videos in XBMC for metadata, and only use file name for metadata. There is some initial work done on mp4 support, but only as a proof of concept and not something that is currently an option in stable XBMC builds.
Reply
#3
Damn. :/
Well, actually it wouldn't even be a big problem, if it would only use the Artist and Title from the file name.
But the weird thing is that the database doesn't seem to know most of my songs. (And just to make this clear, all songs are top 100 single chart songs from 2013 and they are names like you can find them on iTunes.)

Is there maybe a way to tell XBMC that it should simply read the data from the file names and son't use a database at all?
I already tried to use the "Local information only" button when adding the videos, but then I could simply find them as filename.mp4 in the file list and they didn't show up at all in the music videos section.

edit:
I guess for now the only option is using .nfo files? http://wiki.xbmc.org/index.php?title=NFO...usicvideos
But I guess XBMC won't create them for me, so I'll have to write my own parser for that. :/
Reply
#4
Well, I wrote a little script to auto-generate the nfo files by parsing the file names.
It asks you for a file- and file name pattern.
As an example you could enter "c:\music\*.mp4" as file pattern and "%artist% - %title%" as file name pattern.
Maybe someone else also has use for it.
You'll need AutoHotkey to run the script. (just download+install AHK, put the code in a .ahk file and run it)
Code:
;Get folder and pattern from user
InputBox, Path, Enter a file path, Enter a the full path to a file or use the wildcart (*) to use multiple files. ,,,,,,,, %A_ScriptDir%\*.mp4
InputBox, rawPattern, Pattern to parse the filename..., Use any of those in your pattern:`n`%title`%`, `%artist`%`, `%album`%`, `%genre`%`, `%runtime`%`, `%plot`%`, `%year`%`, `%director`%`, `%studio`%`, `%track`%,,,,,,,, `%artist`% - `%title`%

;Quick parse to get the used tags
possibleTags := ["%title%","%artist%","%genre%","%runtime%","%plot%","%year%","%director%","%studio%","%track%"]
usedTags := []
Loop % possibleTags.MaxIndex() {
    If (InStr(rawPattern,possibleTags[A_Index]))
        usedTags.Insert(SubStr(possibleTags[A_Index],2,StrLen(possibleTags[A_Index])-2))
}

;Create actual RegEx pattern
pattern := "O)"
percentOpen := False
escapeChars := "\.*?+[{|()^$"
Loop, Parse, rawPattern
{
    currentChar := A_LoopField
    Loop, Parse, escapeChars
        If (currentChar = A_LoopField)
            currentChar := "\" A_LoopField
    If (currentChar = "%") {
        If (percentOpen)
            currentChar := ">.+)"
        Else
            currentChar := "(?P<"
        percentOpen := !percentOpen
    }
    pattern .= currentChar
}
pattern .= "\.mp4"

;Parse all filenames in the chosen directory
Loop, %Path%,, 1
{
    ;Run the the regex pattern on a file name
    RegExMatch(A_LoopFileName, pattern, MediaInfo)
    
    ;Generate full path to the nfo file that's gonna be created
    nfoFile := SubStr(A_LoopFileFullPath,1,StrLen(A_LoopFileFullPath)-3) "nfo"
    FileDelete, % nfoFile ;Delete in case it already exists
    
    ;Generate nfo content using all the tags the user chose
    nfoContent := "<musicvideo>`n"
    Loop % usedTags.MaxIndex() {
        tagName := usedTags[A_Index]
        nfoContent .= "    <" tagName ">" MediaInfo[tagName] "</" tagName ">`n"
    }
    nfoContent .= "</musicvideo>"
    
    ;Create the nfo file, append the content to it and hide the file
    FileAppend, % nfoContent, % nfoFile
    FileSetAttrib, ^H, % nfoFile
}
Reply

Logout Mark Read Team Forum Stats Members Help
[Music Videos] Don't show allup in the list0