From 056cb0d6992ce1d1e4374a62e8405bfee0dfc487 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Fri, 29 Mar 2013 16:16:35 +0000 Subject: [PATCH] encode larger streams first --- pandora/archive/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandora/archive/models.py b/pandora/archive/models.py index 395c57ba..c64e2892 100644 --- a/pandora/archive/models.py +++ b/pandora/archive/models.py @@ -464,7 +464,7 @@ class Stream(models.Model): def extract_derivatives(self, rebuild=False): config = settings.CONFIG['video'] - for resolution in config['resolutions']: + for resolution in sorted(config['resolutions'], reverse=True): for f in config['formats']: derivative, created = Stream.objects.get_or_create(file=self.file, resolution=resolution, format=f)