HOW-TO:Modify time seeking: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
mNo edit summary
 
(35 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{mininav| [[advancedsettings.xml]] {{l2| [[Video library]] }} }}
{{mininav| [[advancedsettings.xml]] {{l2| [[Video library]] }} }}
<section begin="intro" />This page describes various '''[[advancedsettings.xml]] settings''' that can be used to modify the default seek "steps" in XBMC, commonly mapped to the directional keys during playback (left, right, up, down). By default, up/down is "BigStepForward/Back" +/- 10 minutes, and left/right is "StepForward/Back" +/- 30 seconds. There is also "SmallStepBack", which is -7 seconds.<section end="intro" />
<section begin="intro" />This page describes various '''[[advancedsettings.xml]] settings''' that can be used to modify the default seek "steps" in {{kodi}}, commonly mapped to the directional keys during playback (left, right, up, down). By default, up/down is "BigStepForward/Back" +/- 10 minutes, and left/right is "StepForward/Back" +/- 30 seconds. There is also "SmallStepBack", which is -7 seconds. All of these options can be modified.<section end="intro" />
 
 
{{TOC limit|2}}


== Steps ==
== Steps ==
If you don't already have an [[advancedsettings.xml]] file, it's very simple to make. XBMC uses this file for advanced settings and features that normal users shouldn't modify without first knowing what they do, as well as for experimental features.
If you don't already have an [[advancedsettings.xml]] file, it's very simple to make. Kodi uses this file for advanced settings and features that normal users shouldn't modify without first knowing what they do, as well as for experimental features.


{{how-to
{{how-to
| Step1 = Create a '''plain text file''' (no rich text formatting, don't use .doc, etc) and save it as '''advancedsettings.xml'''. Make sure that the file extension is ".xml" and '''not''' ".txt" or ".xml.txt".
| Step1 = Create a '''plain text file''' (no rich text formatting, don't use .doc, etc) and save it as '''advancedsettings.xml'''. Make sure that the file extension is ".xml" and {{color|red|'''not'''}} ".txt" or ".xml.txt".


| Step2 = Cut and paste this into your new plain text file:
| Step2 = Cut and paste this into your new plain text file:
Line 12: Line 15:
<advancedsettings>
<advancedsettings>
   <video>
   <video>
    <usetimeseeking>true</usetimeseeking>
     <smallstepbackseconds>7</smallstepbackseconds>
     <smallstepbackseconds>7</smallstepbackseconds>
    <usetimeseeking>true</usetimeseeking>
     <timeseekforward>30</timeseekforward>
     <timeseekforward>30</timeseekforward>
     <timeseekbackward>-30</timeseekbackward>
     <timeseekbackward>-30</timeseekbackward>
Line 26: Line 29:
</syntaxhighlight>
</syntaxhighlight>


| Step3 = Change the values between the tags to fit your situation.
| Step3 = Change the values between the tags to fit your situation. See '''[[#Settings explained]]''' for details.


| Step4 = Save this file in your [[userdata folder]]:
| Step4 = Save this file in your [[Userdata|userdata folder]]:
:{{#lst:userdata|location all}}
:{{#lst:userdata|location all}}
{{note|If you have an existing advancedsettings.xml file, make sure the <video></video> tags, and settings we'll add between them, are between the main <advancedsettings></advancedsettings> tags.}}
{{note|If you have an existing advancedsettings.xml file, make sure the <video></video> tags, and settings we'll add between them, are between the main <advancedsettings></advancedsettings> tags.}}
Line 35: Line 38:


== Settings explained ==
== Settings explained ==
{| class="wikitable"
{| class="prettytable"
! advancedsettings.xml tag !! what it does
! advancedsettings.xml tag !! what it does
|-
|-
| <syntaxhighlight lang="xml" enclose="div">
| <code><usetimeseeking>'''true'''</usetimeseeking></code>
<playcountminimumpercent>90</playcountminimumpercent>
 
</syntaxhighlight>
| {{big|'''Use time or percentages'''}}
 
By default, Kodi uses the time tags for videos above 20 minutes, and videos below 20 minutes will use the percentage tags. Set this to '''false''' to only use the percent tags regardless of video length (except for smallstepbackseconds, which has no percent counterpart).
 
|-
| <code><smallstepbackseconds>'''7'''</smallstepbackseconds></code>
 
| {{big|'''Small step back'''}}
 
SmallStepBack is the only "step" in Kodi that doesn't have a forward option. This is because the idea behind SmallStepBack is to quickly jump back and hear a line of dialogue or some quick action that was missed.
|-
| <code><timeseekforward>'''30'''</timeseekforward><br /><timeseekbackward>'''-30'''</timeseekbackward></code>
 
| {{big|'''Normal time jumps'''}} {{small|''Videos longer than 20 minutes''}}
 
This is set in seconds. For minutes simply multiply by 60. A - (minus) sign is used when you want to go backward in the video. The default setting is 30 seconds.
 
|-
| <code><timeseekforwardbig>'''600'''</timeseekforwardbig><br /><timeseekbackwardbig>'''-600'''</timeseekbackwardbig></code>
 
| {{big|'''Big time jumps'''}} {{small|''Videos longer than 20 minutes''}}


| {{huge|'''How much must be viewed to be marked as watched'''}}
This is set in seconds. For minutes simply multiply by 60. A - (minus) sign is used when you want to go backward in the video. The default setting is 10 minutes.


Since a lot of people don't watch credits at the end of a movie or TV show, this value allows us to skip those parts while still automatically marking something as watched. This setting is defined in a percentage with the default being 90 percent.
|-
|-
| <syntaxhighlight lang="xml" enclose="div">
| <code><percentseekforward>'''2'''</percentseekforward><br /><percentseekbackward>'''-2'''</percentseekbackward></code>
<ignoresecondsatstart>180</ignoresecondsatstart>
 
</syntaxhighlight>
| {{big|'''Normal percentage jumps'''}} {{small|''Videos shoter than 20 minutes''}}


| {{huge|'''Time to ignore at the start of a video before making a resume point'''}}
This is set in percentage of the video length. A - (minus) sign is used when you want to go backward in the video. The default setting is 2 percent.


This setting allows someone to start a video, only watch a couple of minutes, and then stop it without recording a resume point. This allows someone to do things such as check to see if the video is one they've seen or not, or to not mark a video if all you have seen is just the opening credits, etc. This setting is defined in seconds with the default being 180 seconds. For whole minutes simply multiply by 60.
For example, a 1 minute video will seek slightly more than 1 second (1.2, to be exact) if seeking back/forward by 2 percent.


|-
|-
| <syntaxhighlight lang="xml" enclose="div">
| <code><percentseekforwardbig>'''10'''</percentseekforwardbig><br /><percentseekbackwardbig>'''-10'''</percentseekbackwardbig></code>
<ignorepercentatend>8</ignorepercentatend>
 
</syntaxhighlight>
| {{big|'''Big percentage jumps'''}} {{small|''Videos shorter than 20 minutes''}}


| {{huge|'''Percent at the end of a video to ignore to prevent making a resume point'''}}
This is set in percentage of the video length. A - (minus) sign is used when you want to go backward in the video. The default setting is 10 percent.


This setting prevents a resume point from being recorded if it is within a certain percentage at the end of the video. The logic here is similar to <playcountminimumpercent>, where most people will probably want to skip end credits and not have a resume point made, as they are done watching the video. The setting is defined in a percentage in relation to the end of the video, and the default is 8 percent. For an hour movie this would ignore a little under 5 minutes from the end of the video.
For example, a 10 minute video will seek 1 minute if seeking back/forward by 10 percent.


|}
|}
Line 67: Line 89:
== Examples ==
== Examples ==


== See also ==
=== Example 1 ===
In this example we have set Kodi to always use percent seeks, so there is no need to include the time seek tags. The percentages used are smaller for more fine-grained control, but anyone who wants truly fine-grain control will most likely want to use time-based seeking rather than percentage-based seeking.
 
;advancedsettings.xml
<syntaxhighlight lang="xml" enclose="div">
<advancedsettings>
  <video>
    <usetimeseeking>false</usetimeseeking>
    <percentseekforward>1</percentseekforward>
    <percentseekbackward>-1</percentseekbackward>
    <percentseekforwardbig>5</percentseekforwardbig>
    <percentseekbackwardbig>-5</percentseekbackwardbig>
  </video>
</advancedsettings>
</syntaxhighlight>
 
=== Example 2 ===
This example shows a simple adjustment of the seeks, which a person might use depending on their own personal preferences. <code><usetimeseeking></code> is excluded here since this person is okay with using time-based tags for videos longer than 20 minutes, and percentage-based tags for videos shorter than 20 minutes (the default).
 
;advancedsettings.xml
<syntaxhighlight lang="xml" enclose="div">
<advancedsettings>
  <video>
    <smallstepbackseconds>5</smallstepbackseconds>
    <timeseekforward>15</timeseekforward>
    <timeseekbackward>-15</timeseekbackward>
    <timeseekforwardbig>60</timeseekforwardbig>
    <timeseekbackwardbig>-60</timeseekbackwardbig>
    <percentseekforward>3</percentseekforward>
    <percentseekbackward>-3</percentseekbackward>
    <percentseekforwardbig>20</percentseekforwardbig>
    <percentseekbackwardbig>-20</percentseekbackwardbig>
  </video>
</advancedsettings>
</syntaxhighlight>
 
=== Example 3 ===
This example is the same as '''[[#Example 2|Example 2]]''', but without the percent-based tags. When any tag is not included it will simply use the default value. If this were a situation were we only wanted to change the time-based seeking, then we would only need to include those tags.
 
;advancedsettings.xml
<syntaxhighlight lang="xml" enclose="div">
<advancedsettings>
  <video>
    <smallstepbackseconds>5</smallstepbackseconds>
    <timeseekforward>15</timeseekforward>
    <timeseekbackward>-15</timeseekbackward>
    <timeseekforwardbig>60</timeseekforwardbig>
    <timeseekbackwardbig>-60</timeseekbackwardbig>
  </video>
</advancedsettings>
</syntaxhighlight>
 
=== Example 4 ===
In this example things get ''weird''. Despite the name of the tags, we can actually use either "forward" or "back" for both forward and backwards seeking, depending on if we use the - (minus) sign or not. While not actually practical, this is one example of how these settings could be used. When using default [[keymaps]] we get the following behavior:
 
* '''Left:''' forward 10 seconds
* '''Right:''' forward 20 seconds
* '''Up:''' forward 30 seconds
* '''Down:''' forward 40 seconds
 
;advancedsettings.xml
<syntaxhighlight lang="xml" enclose="div">
<advancedsettings>
  <video>
    <timeseekforward>10</timeseekforward>
    <timeseekbackward>20</timeseekbackward>
    <timeseekforwardbig>30</timeseekforwardbig>
    <timeseekbackwardbig>40</timeseekbackwardbig>
  </video>
</advancedsettings>
</syntaxhighlight>
 
== Other ways to seek ==
This page simply covers the [[advancedsettings.xml]] values, which typically relate to how the directional keys jump in a video. However, there are many other ways that one can seek back or forward in time when playing a video. See the topics below for some of those methods:
 
* [[Remote controls]]
* [[Remote controls]]
* [[Keymaps]]
* [[Keymaps]]


{{Gotham updated}}
{{Helix updated}}


[[Category:Advanced topics]]
[[Category:Advanced topics]]
[[Category:How-to]]
[[Category:How-to]]
[[Category:Video library]]
[[Category:Video library]]
[[Category:Remotes]]

Latest revision as of 23:31, 24 November 2020

Home icon grey.png   ▶ advancedsettings.xml
▶ Video library
▶ HOW-TO:Modify time seeking

This page describes various advancedsettings.xml settings that can be used to modify the default seek "steps" in Kodi, commonly mapped to the directional keys during playback (left, right, up, down). By default, up/down is "BigStepForward/Back" +/- 10 minutes, and left/right is "StepForward/Back" +/- 30 seconds. There is also "SmallStepBack", which is -7 seconds. All of these options can be modified.


Steps

If you don't already have an advancedsettings.xml file, it's very simple to make. Kodi uses this file for advanced settings and features that normal users shouldn't modify without first knowing what they do, as well as for experimental features.

1 Create a plain text file (no rich text formatting, don't use .doc, etc) and save it as advancedsettings.xml. Make sure that the file extension is ".xml" and not ".txt" or ".xml.txt".
2 Cut and paste this into your new plain text file:
<advancedsettings>
  <video>
    <usetimeseeking>true</usetimeseeking>
    <smallstepbackseconds>7</smallstepbackseconds>
    <timeseekforward>30</timeseekforward>
    <timeseekbackward>-30</timeseekbackward>
    <timeseekforwardbig>600</timeseekforwardbig>
    <timeseekbackwardbig>-600</timeseekbackwardbig>
    <percentseekforward>2</percentseekforward>
    <percentseekbackward>-2</percentseekbackward>
    <percentseekforwardbig>10</percentseekforwardbig>
    <percentseekbackwardbig>-10</percentseekbackwardbig>
  </video>
</advancedsettings>
3 Change the values between the tags to fit your situation. See #Settings explained for details.
4 Save this file in your userdata folder:

The Userdata folder is a subfolder of the Kodi Data Folder and is located as shown in the table below.

Operating system Userdata Folder
Android Android/data/org.xbmc.kodi/files/.kodi/userdata/ (see note)
iOS /private/var/mobile/Library/Preferences/Kodi/userdata/
LibreELEC /storage/.kodi/userdata/
Linux ~/.kodi/userdata/
macOS /Users/<your_user_name>/Library/Application Support/Kodi/userdata/
Nvidia Shield (SMB) smb://<nvidiashieldurl>/internal/Android/data/org.xbmc.kodi/files/.kodi/userdata
OSMC /home/osmc/.kodi/userdata/
tvOS /private/var/mobile/Library/Preferences/Kodi/userdata/
Windows %APPDATA%\Kodi\userdata
Windows Portable <Install location chosen by you>\portable_data\userdata\
Windows via Microsoft Store %LOCALAPPDATA%\Packages\XBMCFoundation.Kodi_4n2hpmxwrvr6p\LocalCache\Roaming\Kodi\
Windows Xbox %LOCALAPPDATA%\Packages\XBMCFoundation.Kodi_4n2hpmxwrvr6p\LocalCache\Roaming\Kodi\
Note: In some Android setups the path may be slightly different to the one stated above.

Note: If you have an existing advancedsettings.xml file, make sure the <video></video> tags, and settings we'll add between them, are between the main <advancedsettings></advancedsettings> tags.


Settings explained

advancedsettings.xml tag what it does
<usetimeseeking>true</usetimeseeking> Use time or percentages

By default, Kodi uses the time tags for videos above 20 minutes, and videos below 20 minutes will use the percentage tags. Set this to false to only use the percent tags regardless of video length (except for smallstepbackseconds, which has no percent counterpart).

<smallstepbackseconds>7</smallstepbackseconds> Small step back

SmallStepBack is the only "step" in Kodi that doesn't have a forward option. This is because the idea behind SmallStepBack is to quickly jump back and hear a line of dialogue or some quick action that was missed.

<timeseekforward>30</timeseekforward>
<timeseekbackward>-30</timeseekbackward>
Normal time jumps Videos longer than 20 minutes

This is set in seconds. For minutes simply multiply by 60. A - (minus) sign is used when you want to go backward in the video. The default setting is 30 seconds.

<timeseekforwardbig>600</timeseekforwardbig>
<timeseekbackwardbig>-600</timeseekbackwardbig>
Big time jumps Videos longer than 20 minutes

This is set in seconds. For minutes simply multiply by 60. A - (minus) sign is used when you want to go backward in the video. The default setting is 10 minutes.

<percentseekforward>2</percentseekforward>
<percentseekbackward>-2</percentseekbackward>
Normal percentage jumps Videos shoter than 20 minutes

This is set in percentage of the video length. A - (minus) sign is used when you want to go backward in the video. The default setting is 2 percent.

For example, a 1 minute video will seek slightly more than 1 second (1.2, to be exact) if seeking back/forward by 2 percent.

<percentseekforwardbig>10</percentseekforwardbig>
<percentseekbackwardbig>-10</percentseekbackwardbig>
Big percentage jumps Videos shorter than 20 minutes

This is set in percentage of the video length. A - (minus) sign is used when you want to go backward in the video. The default setting is 10 percent.

For example, a 10 minute video will seek 1 minute if seeking back/forward by 10 percent.

Examples

Example 1

In this example we have set Kodi to always use percent seeks, so there is no need to include the time seek tags. The percentages used are smaller for more fine-grained control, but anyone who wants truly fine-grain control will most likely want to use time-based seeking rather than percentage-based seeking.

advancedsettings.xml
<advancedsettings>
  <video>
    <usetimeseeking>false</usetimeseeking>
    <percentseekforward>1</percentseekforward>
    <percentseekbackward>-1</percentseekbackward>
    <percentseekforwardbig>5</percentseekforwardbig>
    <percentseekbackwardbig>-5</percentseekbackwardbig>
  </video>
</advancedsettings>

Example 2

This example shows a simple adjustment of the seeks, which a person might use depending on their own personal preferences. <usetimeseeking> is excluded here since this person is okay with using time-based tags for videos longer than 20 minutes, and percentage-based tags for videos shorter than 20 minutes (the default).

advancedsettings.xml
<advancedsettings>
  <video>
    <smallstepbackseconds>5</smallstepbackseconds>
    <timeseekforward>15</timeseekforward>
    <timeseekbackward>-15</timeseekbackward>
    <timeseekforwardbig>60</timeseekforwardbig>
    <timeseekbackwardbig>-60</timeseekbackwardbig>
    <percentseekforward>3</percentseekforward>
    <percentseekbackward>-3</percentseekbackward>
    <percentseekforwardbig>20</percentseekforwardbig>
    <percentseekbackwardbig>-20</percentseekbackwardbig>
  </video>
</advancedsettings>

Example 3

This example is the same as Example 2, but without the percent-based tags. When any tag is not included it will simply use the default value. If this were a situation were we only wanted to change the time-based seeking, then we would only need to include those tags.

advancedsettings.xml
<advancedsettings>
  <video>
    <smallstepbackseconds>5</smallstepbackseconds>
    <timeseekforward>15</timeseekforward>
    <timeseekbackward>-15</timeseekbackward>
    <timeseekforwardbig>60</timeseekforwardbig>
    <timeseekbackwardbig>-60</timeseekbackwardbig>
  </video>
</advancedsettings>

Example 4

In this example things get weird. Despite the name of the tags, we can actually use either "forward" or "back" for both forward and backwards seeking, depending on if we use the - (minus) sign or not. While not actually practical, this is one example of how these settings could be used. When using default keymaps we get the following behavior:

  • Left: forward 10 seconds
  • Right: forward 20 seconds
  • Up: forward 30 seconds
  • Down: forward 40 seconds
advancedsettings.xml
<advancedsettings>
  <video>
    <timeseekforward>10</timeseekforward>
    <timeseekbackward>20</timeseekbackward>
    <timeseekforwardbig>30</timeseekforwardbig>
    <timeseekbackwardbig>40</timeseekbackwardbig>
  </video>
</advancedsettings>

Other ways to seek

This page simply covers the advancedsettings.xml values, which typically relate to how the directional keys jump in a video. However, there are many other ways that one can seek back or forward in time when playing a video. See the topics below for some of those methods: