Kodi Community Forum

Full Version: [testing] Better play episode selection for episodes on ISO
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I've been looking at how episodes are played when they are in an ISO (and I assume BDMV folder as well).

Currently you are asked to select from a list of titles - these are presented in no particular order and (by default) only show those with length 70%+ of the longest.

So, for example, on The Last of Us (UHD Disc 1) - if I try and play episode 2 (disc 1 contains episodes 1 and 2), I get the following:

Image

This demonstrates a number of issues:
1) No clear idea what titles 801 and 851 contain - they actually are both episode 1 (despite us asking to play episode 2)
2) No idea what languages are associated with each title (801 = episode 1 european languages, 851 = episode 1 japanese)

I've updated the code - so now when I select episode 2 I get the following:

Image

This obviously will vary for different discs - So if you have bluray ISO/BDMV episodes I'd be grateful if people can test and report back.

If it works, great. Please let me know here.

If it doesn't work then please look in the *DEBUG* log for the following section (just search for ***)

Code:

2023-12-03 19:22:01.547 T:48436   debug <general>: *** Episodes Start ***
2023-12-03 19:22:01.547 T:48436   debug <general>: Playlist 10, Duration 5, Langs , Clips 00012 
2023-12-03 19:22:01.548 T:48436   debug <general>: Playlist 12, Duration 19, Langs , Clips 00001 
2023-12-03 19:22:01.549 T:48436   debug <general>: Playlist 13, Duration 12, Langs eng, Clips 00011 
2023-12-03 19:22:01.550 T:48436   debug <general>: Playlist 14, Duration 7, Langs , Clips 00055 
2023-12-03 19:22:01.551 T:48436   debug <general>: Playlist 15, Duration 5, Langs , Clips 00062 
2023-12-03 19:22:01.552 T:48436   debug <general>: Playlist 16, Duration 7, Langs , Clips 00008 
2023-12-03 19:22:01.552 T:48436   debug <general>: Playlist 17, Duration 8, Langs , Clips 00053,00003 
2023-12-03 19:22:01.553 T:48436   debug <general>: Playlist 32, Duration 5, Langs , Clips 00017 
2023-12-03 19:22:01.554 T:48436   debug <general>: Playlist 51, Duration 10, Langs , Clips 00056 
2023-12-03 19:22:01.555 T:48436   debug <general>: Playlist 52, Duration 20, Langs , Clips 00000,00054,00005 
2023-12-03 19:22:01.556 T:48436   debug <general>: Playlist 53, Duration 50, Langs , Clips 00013,00016,00018,00019,00020 
2023-12-03 19:22:01.557 T:48436   debug <general>: Playlist 54, Duration 30, Langs , Clips 00002,00006,00007 
2023-12-03 19:22:01.558 T:48436   debug <general>: Playlist 55, Duration 340, Langs , Clips 00004,00010,00021,00022,00023,00024,00025,00026,00027,00028,00029,00030,00031,00032,00033,00034,00035,00036,00037,00038,00039,00040,00041,00042,00043,00044,00045,00046,00047,00048,00049,00050,00051,00052 
2023-12-03 19:22:01.559 T:48436   debug <general>: Playlist 71, Duration 30, Langs , Clips 00063,00064,00065,00005 
2023-12-03 19:22:01.560 T:48436   debug <general>: Playlist 72, Duration 20, Langs , Clips 00066,00067,00005 
2023-12-03 19:22:01.561 T:48436   debug <general>: Playlist 73, Duration 10, Langs , Clips 00009 
2023-12-03 19:22:01.562 T:48436   debug <general>: Playlist 119, Duration 0, Langs , Clips 00005 
2023-12-03 19:22:01.563 T:48436   debug <general>: Playlist 140, Duration 132, Langs eng, Clips 00061 
2023-12-03 19:22:01.564 T:48436   debug <general>: Playlist 201, Duration 314, Langs eng, Clips 00059 
2023-12-03 19:22:01.565 T:48436   debug <general>: Playlist 202, Duration 257, Langs eng, Clips 00060 
2023-12-03 19:22:01.565 T:48436   debug <general>: Playlist 301, Duration 314, Langs eng, Clips 00059 
2023-12-03 19:22:01.566 T:48436   debug <general>: Playlist 302, Duration 257, Langs eng, Clips 00060 
2023-12-03 19:22:01.567 T:48436   debug <general>: Playlist 801, Duration 4849, Langs eng/fra/deu/ita/spa/spa/ces, Clips 00014 
2023-12-03 19:22:01.568 T:48436   debug <general>: Playlist 802, Duration 3169, Langs eng/fra/deu/ita/spa/spa/ces, Clips 00058 
2023-12-03 19:22:01.569 T:48436   debug <general>: Playlist 851, Duration 4849, Langs eng/jpn, Clips 00014 
2023-12-03 19:22:01.570 T:48436   debug <general>: Playlist 852, Duration 3169, Langs eng/jpn, Clips 00058 
2023-12-03 19:22:01.570 T:48436   debug <general>: Looking for episode 2 duration 3180
2023-12-03 19:22:01.570 T:48436   debug <general>: On disc - episode 1 duration 4860
2023-12-03 19:22:01.570 T:48436   debug <general>: On disc - episode 2 duration 3180
2023-12-03 19:22:01.570 T:48436   debug <general>: Candidate title 802 - actual duration 3169, desired duration 3180
2023-12-03 19:22:01.570 T:48436   debug <general>: Candidate title 852 - actual duration 3169, desired duration 3180
2023-12-03 19:22:01.570 T:48436   debug <general>: Playlist group found from 201 to 202
2023-12-03 19:22:01.570 T:48436   debug <general>: Playlist group found from 301 to 302
2023-12-03 19:22:01.570 T:48436   debug <general>: Playlist group found from 801 to 802
2023-12-03 19:22:01.570 T:48436   debug <general>: Playlist group found from 851 to 852
2023-12-03 19:22:01.570 T:48436   debug <general>: Candidate 802 kept as in position 2 in group
2023-12-03 19:22:01.570 T:48436   debug <general>: Candidate 852 kept as in position 2 in group
2023-12-03 19:22:01.570 T:48436   debug <general>: *** Episodes End ***

and paste into a post here. If you know the correct title(s) for the episode(s) please post that as well.

UPDATED 9/12 Test version - https://file.io/DZhLUXzXOLnH - KodiSetup-20231209-ecb08234-play_title_improvement-x64.exe

Thanks
Andy
Hi @powellandy

I've moved your thread into the Development section of the forum.

Looks like a great feature.

Have you submitted a PR to Kodi github? It might be an idea to get feedback on coding from the developers also, but they won't look at it until a PR has been submitted.
Ignore, I was pointed to your PR... https://github.com/xbmc/xbmc/pull/24178

Also, some hints on the editors bar. Button 24 for code...
Image