Python Forum
Segmented video not playing
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Segmented video not playing
#1
I know this is not the right way to approach the problem I am going to solve. I am watching a movie from Hotstar and now I want to download the movie to my desktop. O inspected the page and came to know that it is segmented file that is being loaded.

So I decided to download all the segmented parts of the video and then join them and make a complete video file.

I captured the URL of a segmented part at random and paste it in browser URL, that part is downloaded, and can be played on its own with VLC media player. But when I download the particular segment of the file using Python scripy, it gets downloaded but not VLC can't play the downloaded file.

What's wrong with it? Can anyone help?

import requests

url = 'https://hses.hotstar.com/videos/movies/hindi/1000215554/1000074189/phone/media-4/segment-1000.ts'
r = requests.get(url, allow_redirects=True)
open('hotstar'+str(1)+'.ts', 'wb').write(r.content)
Reply


Messages In This Thread
Segmented video not playing - by Man_from_India - Aug-20-2020, 07:44 AM
RE: Segmented video not playing - by DeaD_EyE - Aug-20-2020, 12:39 PM
RE: Segmented video not playing - by Man_from_India - Aug-21-2020, 04:02 AM
RE: Segmented video not playing - by johnnparry55 - Nov-13-2020, 04:07 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020