Can now stream transcoded version of audio tracks \o/

This commit is contained in:
Eliot Berriot 2018-02-18 23:49:42 +01:00
parent ddea5f1825
commit 1cfdf31e00
No known key found for this signature in database
GPG key ID: DD6965E2476E5C27
2 changed files with 63 additions and 0 deletions

View file

@ -0,0 +1,23 @@
from django import forms
from . import models
class TranscodeForm(forms.Form):
FORMAT_CHOICES = [
('ogg', 'ogg'),
('mp3', 'mp3'),
]
to = forms.ChoiceField(choices=FORMAT_CHOICES)
BITRATE_CHOICES = [
(64, '64'),
(128, '128'),
(256, '256'),
]
bitrate = forms.ChoiceField(
choices=BITRATE_CHOICES, required=False)
track_file = forms.ModelChoiceField(
queryset=models.TrackFile.objects.all()
)