2017-01-12 08:40:31 +13:00
|
|
|
defprotocol Vivid.PNG do
|
2017-01-12 08:55:58 +13:00
|
|
|
alias Vivid.{Shape, Frame, Buffer}
|
2018-09-04 14:52:12 +12:00
|
|
|
|
2017-01-12 08:40:31 +13:00
|
|
|
@moduledoc """
|
|
|
|
Turn a Vivid frame or shape into a PNG
|
|
|
|
"""
|
|
|
|
|
|
|
|
@doc """
|
|
|
|
Turn a frame or shape into a PNG file.
|
|
|
|
"""
|
2018-09-04 14:52:12 +12:00
|
|
|
@spec to_png(Shape.t() | Frame.t() | Buffer.t(), Path.t()) :: :ok | {:error, any}
|
2017-01-12 08:40:31 +13:00
|
|
|
def to_png(shape, file)
|
|
|
|
end
|