Skip to content

Commit

Permalink
revert: media processing
Browse files Browse the repository at this point in the history
images were starting to get downloded to videos, i'll deal with it later
  • Loading branch information
agnosto committed Aug 18, 2024
1 parent 9b1afc6 commit a7a4be0
Showing 1 changed file with 0 additions and 19 deletions.
19 changes: 0 additions & 19 deletions download/timeline.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,25 +292,6 @@ func (d *Downloader) downloadSingleItem(ctx context.Context, item posts.MediaIte
//log.Printf("\n[Main Media Height] H: %v", bestHeight)
//log.Printf("\n[MAIN Media URL] %v\n", mediaUrl)
}

// Process variants if main location is empty
if mediaUrl == "" {
for _, variant := range mediaItem.Variants {
if len(variant.Locations) > 0 && variant.Height > bestHeight {
bestMedia = &posts.MediaItem{
ID: variant.ID,
Type: variant.Type,
Height: variant.Height,
Mimetype: variant.Mimetype,
Locations: variant.Locations,
}
bestHeight = variant.Height
bestMetadata = variant.Locations[0].Metadata
mediaUrl = variant.Locations[0].Location
}
}
}

if d.M3U8Download && d.ffmpegAvailable {
//log.Printf("[FFMPEG] Status: %v", d.ffmpegAvailable)
for _, variant := range mediaItem.Variants {
Expand Down

0 comments on commit a7a4be0

Please sign in to comment.