Jump to content

Trailers quality


raudraido

Recommended Posts

raudraido
1 hour ago, DeanoDublin said:

It’s terrible that this has gone on so long. To me it looks like the Emby team simply ticked a box to get this to work. The fact that the quality is so absolutely terrible that it makes the functionality unusable seems not to matter. 

I would love to hear from even ONE Emby user that uses this feature. 

<!DOCTYPE html>
<html>
<head>
</head>
<body>
<video id="player" controls="controls" width="100%">
    <source src="https://movietrailers.apple.com/movies/wb/tenet/tenet-trailer-2_h1080p.mov">
</video>
</body>
</html>

Copy this code and save it to html format and open it, and VOILA you have an 1080p trailer video :)
Why Emby can not use apple trailers as many other sites do? Legal resons?
Why no response what is going on?

Edited by raudraido
  • Like 1
Link to comment
Share on other sites

I use trailers but changed many of them to 1080 myself.  I just did an edit of the database and change them from 480 to 1080 using a replace statement.

But that doesn't help with getting old trailers and not getting the new ones. The plugin could use a bit of love.

Link to comment
Share on other sites

  • 3 weeks later...
  • 3 weeks later...
  • 2 weeks later...
crusher11
On 9/30/2020 at 1:59 PM, cayars said:

I use trailers but changed many of them to 1080 myself.  I just did an edit of the database and change them from 480 to 1080 using a replace statement.

But that doesn't help with getting old trailers and not getting the new ones. The plugin could use a bit of love.

What did you edit? 

Link to comment
Share on other sites

FrostByte
20 minutes ago, crusher11 said:

What did you edit? 

I'm sure @cayars would be more than happy to walk you through editing your db.  He's an expert at

  • Like 2
Link to comment
Share on other sites

Yes, I can put together a quick tutorial how to do this.  Let me wipe my test system to reload the data and see what SQL is needed.  Get back to you in a bit.

Link to comment
Share on other sites

I've tried to make this easy for windows users.  Attached is a zip file that contains 3 files:
sqlite3.exe - This is a database editor that runs from the command line
FixTrailers.bat - This is a windows batch file that will run this for you in one click
FixTrailers.sql - This contains the sql that runs

1. Unzip this file into your main Emby folder.  For me this is C:\Users\Administrator\AppData\Roaming\Emby-Server on windows
2. Shutdown Emby
3. Run the batch file.  This will likely be very fast and seem like it didn't do anything but it did

NOTE: As always it's a good idea to make a copy of the library.db which will be in the programdata\data library..  I would do this at least for the first run to make sure everything is working correctly.

Contents of the sql file:
 

UPDATE MediaItems SET Path = replace( Path, 'h480p.mov', 'h1080p.mov') where type=10 and Path like '%h480p%';

This changes the url of trailers that are 480 to 1080.  It only adjusts type 10 data which are trailers.

Contents of batch file

sqlite3.exe .\programdata\data\library.db ".read FixTrailers.sql"

This runs the sqlite3 program directing it to edit the library.db and executes the sql mentioned above.
It's important to place these files in the proper spot so the script can find the files.

If you have your own favorite sqlite editor and know how to run SQL simply use the sql contained in the FixTrailers.sql file.

You will need to run this from time to time to update any new URLs that get added to your system.

Let me know if you have any questions,

Carlo

 

FixTrailers.zip

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

crusher11

It's not a Windows install, it's a Synology install, but if I run that .bat in Windows in the equivalent folder it should still work, right?

 

Link to comment
Share on other sites

Here's a bonus script for finding duplicate movies on your system based on MetaData (not file names).  This works very similar to the above script where you have a batch file and a sql file.  The only difference is this outputs a text file DuplicateMovies.txt

The text file will have the name of the movie, pipe symbol "|" followed by the year.

 

DupeMovies.zip

Link to comment
Share on other sites

5 minutes ago, crusher11 said:

It's not a Windows install, it's a Synology install, but if I run that .bat in Windows in the equivalent folder it should still work, right?

 

What you could do is shutdown Emby and copy the the library.db file to a windows directory where you have scripts installed. Put the library.db file in the same directory.
After running the script copy the db back and restart windows.

Modify the batch file to this

sqlite3.exe library.db ".read FixTrailers.sql"

 

Link to comment
Share on other sites

crusher11

It deleted all my libraries...I replaced it with the backup but they're still gone. I only have Trailers and Live TV listed.

Edited by crusher11
Link to comment
Share on other sites

This script doesn't delete anything and only modifies the URL of trailers.  I'd suggest you revert back to your backup of the library.db file.

If you like zip your library.db file and PM it to me and I'll run the SQL on it and send it back to you.

Link to comment
Share on other sites

crusher11

Like I said, I reverted to a backup and my libraries are still all gone. Opened it in DB Browser and there's nothing there. Everything is gone.

Link to comment
Share on other sites

If you reverted to a backup then you just eliminated the script from the issue. You have something else wrong.

Please open a new thread and post your server log.

Link to comment
Share on other sites

crusher11

It seems like a waste of time anyway, as all my trailers are URLs like this: "https://cdn-mlst.nyc3.digitaloceanspaces.com/classics/oneflewoverthecuckoosnest.mov"

Which wouldn't be affected in the first place.

Managed to get my library back. Not sure how it got blanked, but I still had the backup in the working folder so I recopied it and we're all good. But, yeah, not sure how this is supposed to help much.

 

Link to comment
Share on other sites

8 minutes ago, raudraido said:

It works, but emby does not recognize more than 480p :)

After I run the scrip this is what I get

image.png.6dc878b60a2ce28e64c557355871cc56.png

If I edit the metadata for Astro Kid I get this:

image.png.4fc1adb36095142bd19c0a41aae3c808.png

This clearly shows the trailer changed from 640 to 1080.

Can you check the meta-data to see what your link is.

Link to comment
Share on other sites

raudraido
2 minutes ago, cayars said:

After I run the scrip this is what I get

image.png.6dc878b60a2ce28e64c557355871cc56.png

If I edit the metadata for Astro Kid I get this:

image.png.4fc1adb36095142bd19c0a41aae3c808.png

This clearly shows the trailer changed from 640 to 1080.

Can you check the meta-data to see what your link is.

Yes, it is actually 1080p, but for emby it is stil 480p somehow. Quality button does not show anything above 480p to choose from

Link to comment
Share on other sites

I wonder if it saves the previous video meta data.  Try "Black Widow" trailer and go to the detail screen.

image.png.c3a5a3c6d98ccf811bba3f38e8efdf9d.png

If you've not played it before there will not be video info highlighted in the yellow box.  BEFORE playing check the URL by editing meta-data and make sure it's the 1080 version.  Then try playing and see if it shows 1080p H264 as above.

Link to comment
Share on other sites

raudraido
4 minutes ago, cayars said:

I wonder if it saves the previous video meta data.  Try "Black Widow" trailer and go to the detail screen.

image.png.c3a5a3c6d98ccf811bba3f38e8efdf9d.png

If you've not played it before there will not be video info highlighted in the yellow box.  BEFORE playing check the URL by editing meta-data and make sure it's the 1080 version.  Then try playing and see if it shows 1080p H264 as above.

Yes, that's the case.

But obviously Apple is slowing down those trailers download speed. I can not stream them live. I think scheduled  trailers download task is needed :) 

Edited by raudraido
Link to comment
Share on other sites

They play fine for me at 1080p with no speed issues. Maybe it's a Geolocation issue?

You could modify the script and try 720p and see if that performs better.

Link to comment
Share on other sites

raudraido
6 minutes ago, cayars said:

They play fine for me at 1080p with no speed issues. Maybe it's a Geolocation issue?

You could modify the script and try 720p and see if that performs better.

Ok, all good now. My dualWAN setup didn't work properly somehow :S 

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...