Conversation
| spec: | ||
| :always | ||
| | :if_needed | ||
| | :never |
There was a problem hiding this comment.
It looks a bit off to me, having a transcoder with transcoding_policy: :never :D Let's try thinking about
other option name, perhaps emphasising somehow that there are "heavy" operations and "light operations" would be helpful here?
There was a problem hiding this comment.
Hmm, my first idea was to add forbid_transcoding? flag next to the force_transcoding?, then I thought that transcoding_policy will sound much better that these 2 combined. Do you propose any specific option name and values?
There was a problem hiding this comment.
Option could be called something like :heavy_operations_policy, or perhaps we should rename the bin since it not only does transcoding
lib/transcoder.ex
Outdated
| * a boolean, | ||
| * a function that receives the input stream format and returns a boolean. | ||
| * an atom: `:always`, `:if_needed` (default) or `:never`, | ||
| * a function that receives the input stream format and returns an atom. |
There was a problem hiding this comment.
| * a function that receives the input stream format and returns an atom. | |
| * a function that receives the input stream format and returns the atom. |
or perhaps it would be even better if you listed all the atoms once again
| If set to `:never`, the input media stream won't be neither decoded nor transcoded. | ||
| Changing alignment, encapsulation or stream structure is still possible. This option | ||
| is helpful when you want to ensure that #{inspect(__MODULE__)} will not use too much | ||
| of resources, e.g. CPU or memory. |
There was a problem hiding this comment.
Please mention that transcoder will fail if the output format doesn't match input.
lib/transcoder.ex
Outdated
| stream format and the output stream format are different types. | ||
| This is the default behavior. | ||
|
|
||
| If set to `:never`, the input media stream won't be neither decoded nor transcoded. |
There was a problem hiding this comment.
It won't be encoded either, for instance in scenario with input: RawVideo and output: H264
Co-authored-by: Łukasz Kita <lukasz.kita0@gmail.com>
No description provided.