Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem choice resolution video #63

Open
Virusf opened this issue Mar 12, 2019 · 8 comments
Open

Problem choice resolution video #63

Virusf opened this issue Mar 12, 2019 · 8 comments

Comments

@Virusf
Copy link

Virusf commented Mar 12, 2019

Hi people

someone would have a solution because the choice of resolution no longer works and whatever the choice the resolution is 1080p?

sorry for my english which is google translation

@Elegond
Copy link

Elegond commented Mar 12, 2019

i haven't looked at the selection of the resolution yet but crunchyroll doesn't send the resolution in the xml answer anymore since today.

@Elegond
Copy link

Elegond commented Mar 12, 2019

I think the quality in altfuncs.py line 20 needs to be remapped but I don't have the time to test it right now.

@nigoki2
Copy link

nigoki2 commented Mar 13, 2019

Thank you Elegond.
Now I have to find how to download in 720p.

@rs3mk
Copy link

rs3mk commented Mar 17, 2019

you can extract quality from the link of the stream

resolution

example:

ffmpeg -i "https://dl.v.vrv......." -map p:0 -c copy "720p.ts"
ffmpeg -i "https://dl.v.vrv......." -map p:1 -c copy "1080p.ts"
ffmpeg -i "https://dl.v.vrv......." -map p:2 -c copy "480p.ts"

@nigoki2
Copy link

nigoki2 commented Mar 17, 2019

@rs3mk How to put this in the script ?

@rs3mk
Copy link

rs3mk commented Mar 24, 2019

edit:
ultimate.py
video_hls(filen, video_input, vquality)
ultimate

hls.py

def find_720_video(uri, vquality):
    playlist = m3u8.load(uri)
    if not playlist.is_variant:
        return playlist
    best_stream = playlist.playlists[0]
    for stream in playlist.playlists:
        if stream.stream_info.bandwidth == 'max' or stream.stream_info.resolution == vquality:
            best_stream = stream
    return find_720_video(best_stream.absolute_uri, vquality)
	
def video_hls(uri, output, vquality):
	if vquality == "720p":
		vquality = "1280x720"
		video = find_720_video(uri, vquality)
		fetch_encryption_key(video)
		fetch_streams(output, video)	
	else:
		video = find_best_video(uri)
		fetch_encryption_key(video)
		fetch_streams(output, video)

hls

@nigoki2
Copy link

nigoki2 commented Mar 24, 2019

@rs3mk Thanks for your help but it doesn't work with me. After editing ultimate.py and hls.py the script still downloads in 1080p.

@alzamer2
Copy link
Collaborator

can you try this code
https://github.com/alzamer2/Crunchyroll-XML-Decoder-py3
i re-write it to use python3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants