changes with video.codecId

All your suggestions, requests and ideas for future development
Post Reply
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

changes with video.codecId

Post by Eye »

did the behavior Of {video.codecId} get changed with v4.7?

i suddenly Get in for example [ V_MPEG4/ISO/AVC]
instead of : V_MPEG4 ISO AVC

and especially the "/" mess up the folders quite nicely;
i tried to replace them but did not get that working either


Thanks
Eye
kim
Power User
Posts: 1251
Joined: 15 May 2014, 16:17

Re: changes with video.codecId

Post by kim »

Generic MediaInfo bindings {video}, {audio}, etc are now multi-stream bindings (and {videos}, {audios}, etc have consequently been removed)
viewtopic.php?f=7&t=3709

maybe use video[0].codecID
video.codecID.join('')
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: changes with video.codecId

Post by rednoah »

1.
Yes, that behaviour has changed.

To get the codec id for video stream 1 you can do this:

Code: Select all

video[0].codecID
However, the generic mediainfo binding do not strip / characters away automatically anymore.


2.
If you use generic mediainfo bindings, you need to think about how you want to deal with multi-stream information and special characters:

Code: Select all

{video.codecID.join('-').replace('/', '.')}

3.
Out of curiosity, why not just use the {vc} binding?
:idea: Please read the FAQ and How to Request Help.
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

Re: changes with video.codecId

Post by Eye »

Thnaks a lot!


i use now
{n.take(40)} - {s.pad(2)+'x'}{e.pad(2)}{' Special '+special.pad(2)} - {t.take(40)} - [{any{group}{'NoGroup'}}] {source} [{resolution}] {video.codecID.join('-').replace('/', ' ')} {[vc, VF, af]} [{video.bitdepth.join('-')} {'Bit'}] {audios.language}{'; '+texts.Language_String2}

for main purposes ;) ( with e,pad(3) for over 100 and such

As you see i use VC and the Troublemaker video.codecID Because the information i got from them were different and I tried to trace were the problems i got with my raspberry Pi were coming from,
And now its kind of tradition and i don't whant to restart renaming everything again ( yes i am a neat freak in that regard ;) )

The problems seems to come form The video.bitdepth, as 8 bit Work fine; But 10 as some have gets my poor old Pi the shakes
"hi10bit" is a feature normally used as a Studio feature but some ppl ...

i just saw video.bitdepth Now comes with added [] I will have to Fidel that a bit too ;)
edit the fiddling result

future goals For sometime: automatic version adding and multiEps ;)
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: changes with video.codecId

Post by rednoah »

1.
* Multi-Episode support (assuming FileBot has detection the episode as such)
* 2/3-digit absolute numbers depending on number of episodes

Code: Select all

{es*.pad(episodelist.size() >= 100 ? 3 : 2).join('-')}
However, you should be using {sxe}. Doing it yourself will burn you, e.g. with special cases like multi-episode objects.


2.
Check if the video contains a 10bit video stream:

Code: Select all

video.BitDepth.contains('10') ? 'NO PIE' : 'GO PIE'

3.
FYI, your format uses audios and texts which have been removed, same as videos.
:idea: Please read the FAQ and How to Request Help.
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

Re: changes with video.codecId

Post by Eye »

1) Your code works With normal tv series too giving 10x002 even if The season only has 20 eps or so ,..

and yes its troublesome but if i go with sxe i Get troubles with the anime renaming and the lack of seasons there Thats why i started On that burning road ,)

2) [{video.bitdepth.join('-')} {'Bit'}] Seems tow work now,
either giving [8-bit], [10-bit] Or something like [undefined]
also there are Threats On the horizon some what to implement 12 Bit color

3) so no more audio stream / sub listing?
is there an other way?
{languages}][{lang}] doesnt seem to make it

added ;)
is there a way to have the Code window warp at the corner and go multi line, that would make working with it a bit more comfortable?

And rednoah
Thanks you for giving uns That Cool Tool!
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: changes with video.codecId

Post by rednoah »

1.
Only for Anime then:

Code: Select all

{es*.pad(anime && episodelist.size() >= 100 ? 3 : 2).join('-')}

2.
r3933 adds {bitdepth}

Code: Select all

{bitdepth > 8 ? 'NO PIE' : 'GO PIE'}

3.
Yes there is: audio and text


4.
If you need more than one line, then you should probably use an external editor.
:idea: Please read the FAQ and How to Request Help.
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

Re: changes with video.codecId

Post by Eye »

I changed ] {audios.language}{'; '+texts.Language_String2}
to {audio.language}{'; ' +text.language}

It works as long as the parameter is filled sadly sometimes i get "[null]" and i did not get a working replace That only works with that ;(

Tried
{audio.language}.replace('[null]', ' '){'; ' +text.language}
{audio.language.replace('[null]', ' ')}{'; ' +text.language}
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: changes with video.codecId

Post by rednoah »

e.g.

Code: Select all

{[1, null, 2].findAll()}
Keep in mind that you're dealing with a List, not a String, which is why you can't use the String.replace() method on the List object.

@see http://stackoverflow.com/questions/3285 ... -in-groovy


EDIT:

This looks like the best solution! :D
http://stackoverflow.com/a/5270663/1514467
:idea: Please read the FAQ and How to Request Help.
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

Re: changes with video.codecId

Post by Eye »

{audio.language.findAll {it != null}}​ {'; ' +text.language} Seems to do the work done except fpr one thing:

If there is a "Null" flag it get an empty []
as i can not threatt that as string,.. i cant go for the replace Fuction here either,.. any added tip?
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: changes with video.codecId

Post by rednoah »

Code: Select all

{[].findAll() ?: 'EMPTY LIST'}
:idea: Please read the FAQ and How to Request Help.
Eye
Posts: 34
Joined: 07 Oct 2014, 21:22

Re: changes with video.codecId

Post by Eye »

I think i got it now

{n.take(40)} - {s.pad(2)+'x'}{e.pad(2)}{' Special '+special.pad(2)} - {t.take(40)} - [{any{group}{'NoGroup'}}] {source} [{resolution}] {video.codecID.join('-').replace('/', ' ')} {[vc, VF, af]} [{video.bitdepth.join('-')} {'Bit'}] {[audio.language].findAll{[null] != it}.join (", ")}​{'; ' +text.language}

Edit:
Little Correction
Post Reply