apng: Convert static pngs to animated png

Description Usage Arguments Value Examples

View source: R/apng.R

Description

Combine multiple png files into an animated png file.

Usage

1
2
3
4
apng(input_files = c(), output_file = "output.png",
num_plays = 0, delay_num = 0, delay_den = 0,
dispose_op = APNG_DISPOSE_OP_NONE,
blend_op = APNG_BLEND_OP_SOURCE)

Arguments

input_files

to specify the names of the input files

output_file

the name of the output file

num_plays

the amount of times to repeat the animation (0 means forever)

delay_num

the numerator of the frame delay (delay = delay_num / delay_den)

delay_den

the denominator of the frame delay (delay = delay_num / delay_den)

dispose_op

the frame disposal strategy
(APNG_DISPOSE_OP_NONE, APNG_DISPOSE_OP_BACKGROUND,
APNG_DISPOSE_OP_PREVIOUS)

blend_op

the frame blending strategy
(APNG_BLEND_OP_SOURCE, APNG_BLEND_OP_OVER)

For more information on blending and frame disposal strategies see https://wiki.mozilla.org/APNG_Specification.

Value

Returns nothing, output is written to output_file.

Examples

1
2
3
4
5
6
7
png(filename="1.png")
plot(1:40, (1:40)^2)
dev.off()
png(filename="2.png")
plot(1:40, (-1*1:40)^3)
dev.off()
apng(c("1.png", "2.png"))

qstokkink/apng documentation built on Dec. 13, 2020, 3:43 a.m.