Kodi Community Forum

Full Version: High-Definition Video Flagging (library filtering/sorting & skin thumbnails overlay)?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
CapnBry Wrote:Yes the streamdetails loader runs from the ThumbLoader thread, so it probes the files when it is time to display the information. EDIT: If you have .nfo files with the streamdetails in them, that information is saved during the library scan and no probe is done.

No skin supports pulling the information yet, so the only way to know if it is working is looking in the DB or editing a skin to show the info, like the PM3.HD change I posted on page 16 (edit the file ViewsVideoLibrary.xml)

CrashX: I've reverted my svn repository, applied patch 5 and it compiles here so I'm not sure what problem you're experiencing.

I am sorry it wasn't your change but someone else on trunk.. It seems to be fixed now .. thanks ...
MaxNL Wrote:CAP it looks like there isn't the aspect ratio... Am I right?
Errrr there is but it isn't exposed to the skin. The issue is that the aspect ratio varies depending on how much the original file has been chopped down. What is left is a ballbark estimate of the aspect ratio that I store in a string. The value ends up being like 1.76, 1.77, 1.78 for 16:9 content.

Now that I think about it, if I stored the original float I might be able to do something like I do for the VideoResolution. Let me think about that some more.

EDIT: After monkeying with it a bit it appears that I can hit with a reasonable level of accuracy. I've got the following strings which you'll get from ListItem.VideoAspect
4-3 = video standard
3-2 = 35mm film (probably don't need this but what the heck)
16-9 = video widescreen
1.85-1 = theatrical widescreen
2.20-1 = 70m standard
2.35-1 = anamorphic widescreen, includes both the old 2.35 and 2.39 actual aspects.

EDIT 2: I've modified this list. See description in post 342
CapnBry Wrote:Errrr there is but it isn't exposed to the skin. The issue is that the aspect ratio varies depending on how much the original file has been chopped down. What is left is a ballbark estimate of the aspect ratio that I store in a string. The value ends up being like 1.76, 1.77, 1.78 for 16:9 content.

Now that I think about it, if I stored the original float I might be able to do something like I do for the VideoResolution. Let me think about that some more.

Isn't it possible for skinners to use the aspect ratio in a boolean statement for their images and then decide to check if aspect ratio is >1.7 AND <1.8 for a 16:9 pic and maybe >1.8 for just a widescreen picture etc. This way the skinner can decide how he wants to group the ratios to the pictures he has and you wouldn't have to concern yourself with that issue.

I think providing three attributes VideoWidth, VideoHeight and VideoRatio should be enough information for skinners to do all sorts of stuff.
ccMatrix Wrote:Isn't it possible for skinners to use the aspect ratio in a boolean statement for their images and then decide to check if aspect ratio is >1.7 AND <1.8 for a 16:9 pic and maybe >1.8 for just a widescreen picture etc.
No you can't do comparisons in the skin, only boolean things. They could probably be clever and say like substr("1.7",ListItem.VideoAspect) but that seems hard still.

I just found this nice page over at IMDB that lists films by aspect ratio. Based on that I'm going to drop 3:2 and add 1.66:1 (flat) as "1.66-1". Should 4-3 and 16-9 be expressed as 1.33-1 and 1.78-1? Yes they should be.
Alright major change here. You must remove your previous streamdetails table if you've been running a v5 or below patch!
To remove table on linux use the sqlite3 command line utility:
Code:
sqlite3 ~/.xbmc/userdata/Database/MyVideos34.db
update version set idVersion = 26;
drop table streamdetails;
.quit
On windows, use a tool like SQLiteSpy or the sqlite command line tool and open the video database in AppData/Roaming/XBMC/UserData/Database/MyVideos34.db and execute the two sql statements from above. When you run xbmc next it will recreate the table.

HDFlagging patch v6
-- Adds VideoAspect
CapnBry Wrote:No you can't do comparisons in the skin, only boolean things. They could probably be clever and say like substr("1.7",ListItem.VideoAspect) but that seems hard still.

I just found this nice page over at IMDB that lists films by aspect ratio. Based on that I'm going to drop 3:2 and add 1.66:1 (flat) as "1.66-1". Should 4-3 and 16-9 be expressed as 1.33-1 and 1.78-1? Yes they should be.

Since all aspect rations are X:1 - is the :1 part even relevant or could you just list 1.33 and 1.78 etc ?
ccMatrix Wrote:Since all aspect rations are X:1 - is the :1 part even relevant or could you just list 1.33 and 1.78 etc ?

http://www.imdb.com/title/tt0104691/

The Last of the Mohicans,

Aspect ratio
2.20 : 1 (70 mm prints)
2.35 : 1

Think outside the box, please.

Ahh, never mind. You are asking about dropping the :1 part. Maybe is redundent but why not include it just in case Smile
davilla Wrote:http://www.imdb.com/title/tt0104691/

The Last of the Mohicans,

Aspect ratio
2.20 : 1 (70 mm prints)
2.35 : 1

Think outside the box, please.

They are still :1 and would be listed as 2.20 and 2.35 instead of 2.20-1 and 2.35-1.

The diff shows that at the moment 1.33-1, 1.66-1, 1.78-1, 1.85-1, 2.20-1 and 2.35-1 would be displayed.
ccMatrix Wrote:The diff shows that at the moment 1.33-1, 1.66-1, 1.78-1, 1.85-1, 2.20-1 and 2.35-1 would be displayed.
I left them on in the current iteration as a differentiation between aspect ratio and some other value. I don't think there will be any collisions if it were 1.33 vs 1.33-1 but I wanted to be sure. It is probably true they are not needed though.
CapnBry Wrote:I left them on in the current iteration as a differentiation between aspect ratio and some other value. I don't think there will be any collisions if it were 1.33 vs 1.33-1 but I wanted to be sure. It is probably true they are not needed though.

ok, makes sense.

Looking forward to the patch applied to main branch and AEON making use of it Wink Thanks for all your work on this!
Here is the compiled Windows version with patch v6 for those who want to play around with. And those who want to skin it. Wink
freezy Wrote:Here is the compiled Windows version with patch v6 for those who want to play around with. And those who want to skin it. Wink

Thanks a lot. I have been waiting for this Smile
For the skinners out their, I am looking forward to seeing proper PM3.HD mod for this ..Big GrinBig Grin
how would those new items translate in .nfo tags, so media manager devs can start using them as well, and if so, will XBMC nfo scraper know how to use them?
I don't mind hacking my nfo files manually to add the extra tags if the scraper will pick them up on this branch.
bidossessi Wrote:how would those new items translate in .nfo tags, so media manager devs can start using them as well, and if so, will XBMC nfo scraper know how to use them?
I don't mind hacking my nfo files manually to add the extra tags if the scraper will pick them up on this branch.
Here's an example. Of course, you'll have a lot more stuff inside the movie tag, but the relevant section is fileinfo/streamdetails/[video|audio|subtitle]
Code:
<movie>
    <fileinfo>
        <streamdetails>
        <video>
            <codec>h264</codec>
            <aspect>2.399999</aspect>
            <width>1920</width>
            <height>816</height>
        </video>
        <audio>
            <codec>ac3</codec>
            <language>eng</language>
            <channels>2</channels>
        </audio>
        <audio>
            <codec>dca</codec>
            <language>eng</language>
            <channels>6</channels>
        </audio>
        <subtitle>
            <language>eng</language>
        </subtitle>
        <subtitle>
            <language>deu</language>
        </subtitle>
        </streamdetails>
    </fileinfo>
</movie>
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43