-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
get pixel formats and sample formats
- Loading branch information
Showing
12 changed files
with
66 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
defmodule Xav do | ||
@moduledoc File.read!("README.md") | ||
|
||
@doc """ | ||
Get all available pixel formats. | ||
The result is a list of 3-element tuples `{name, nb_components, hw_accelerated_format?}`: | ||
* `name` - The name of the pixel format. | ||
* `nb_components` - The number of the components in the pixel format. | ||
* `hw_accelerated_format?` - Whether the pixel format is a hardware accelerated format. | ||
""" | ||
@spec pixel_formats() :: [{atom(), integer(), boolean()}] | ||
def pixel_formats(), do: Xav.Decoder.NIF.pixel_formats() |> Enum.reverse() | ||
|
||
@doc """ | ||
Get all available audio sample formats. | ||
The result is a list of 2-element tuples `{name, nb_bytes}`: | ||
* `name` - The name of the sample format. | ||
* `nb_bytes` - The number of bytes per sample. | ||
""" | ||
@spec sample_formats() :: [{atom(), integer()}] | ||
def sample_formats(), do: Xav.Decoder.NIF.sample_formats() |> Enum.reverse() | ||
end |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.