Stacking: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
>Sho
(TV episode stacking)
 
(10 intermediate revisions by 6 users not shown)
Line 1: Line 1:
When in [[Videos#File View|File Mode]], XBMC has the ability to recognize and present 'multi-part' video files based on filename stacking rules. For example a two part VCD can be displayed and played as a single file in the user interface. This is the default behavior of the [[video library]].
#REDIRECT [[Naming_video_files/Movies#Split_Video_Files]]
 
==Stacking in XBMC==
Stacking can be toggled on / off while in [[Videos#Files View|File Mode]] in My Videos.
How stacked files are presented to the user can be configured with the  [[Videos Settings#General|Treat Stacked Files as a Single File]] under Video Setings.
The default stacking rules are rather "wide" and can cause files you normally would not want to stack to be stacked (e.g. rolling filenames from  digital cameras, TV shows etc.) 
The regular expressions that control stacking can be changed by the [[advancedsettings.xml#.3Cmoviestacking.3E|moviestacking ]] tag in [[advancedsettings.xml]].
 
* Stacking is only available for video media.
* Stacking is disabled by default for files that have been designated as TV shows (via [[How_To_use_Scrapers#Setting_Contents|Set Contents]]). Even if you do not want to use the [[Video Library]] for TV shows, you can use this feature to prevent your TV episodes from being collapsed via stacking.
* An exception to the above is if you use the [[Videos_Settings#Library|Stack Duplicate TV Shows Video Library Setting]].
 
===General Stacking Filename Syntax===
As an example, if you only want to have filenames ending with a specific type of string (e.g. "-CD1", "-CD2" disregarding the extension) collapsed into '''one file'''. Then you would do the following changes in [[advancedsettings.xml]].
 
<xml>
<advancedsettings>
  <moviestacking append="no">
    <regexp>[ _\.-]+cd[ _\.-]*([0-9a-d]+)</regexp>
    <regexp>[ _\.-]+dvd[ _\.-]*([0-9a-d]+)</regexp>
    <regexp>[ _\.-]+part[ _\.-]*([0-9a-d]+)</regexp>
  </moviestacking>
</advancedsettings>
</xml>
 
The syntax can be summarized by the following:
 
'''[token][cd|part|dvd][num]'''
 
Where [token] is one of the following strings:
*"-" (hyphen)
*" " (blank)
*"_" (underscore)
*"." (dot)
 
Followed by the string "cd", "part"  or "dvd" '''(case insensitive)'''.
 
[num] can be a number between 1 and 99.
 
The comparison is case insensitive.
 
For example, if you have the following two files (which both consist of a part of a movie):
 
* MyVideo-CD1.avi
* MyVideo-CD2.avi
 
They will be displayed in the file list as one file '''MyVideo.avi'''.
 
===TV Show Stacking Filename Syntax===
"Stack Duplicate TV Shows" needs to be enabled in settings (see above).
The files have the same season and episode number and all they are in the same path. (This is to prevent unwanted stacking of true duplicates in different folders.
The items will be automatically stacked in sequential order based off the filenames being sorted in a "natural" order (like this: -part1.avi, -part2.avi, ..., -part10.avi.)
 
If you have multi-file episodes where only one part was already scanned into the database, you'll need to make sure that you force the content hash to change before scanning again. This can be done by simply adding a zero byte "foo.avi" to the folder.
 
[[category:Customization]]
[[category:Settings]]
[[category:Usage]]

Latest revision as of 07:26, 21 July 2020