< 3DS:BAX
m (CM360 moved page 3DS:BAX/Usage to 3DS:BAX/makebax: This page was mostly about makebax anyways so it didn't make much sense as "usage") |
(Finish instructions on creating .BAX animations) |
||
Line 10: | Line 10: | ||
=== What You Need === | === What You Need === | ||
* The latest release of | * The latest release of {{GitLab|Wolfvak/BAX/-/releases|makebax}} (It's in the <code>release.zip</code> file) | ||
* The latest release of [https://ffmpeg.org/download.html ffmpeg] installed on your computer | * The latest release of [https://ffmpeg.org/download.html ffmpeg] installed on your computer | ||
Line 16: | Line 16: | ||
# Open a terminal on your computer | # Open a terminal on your computer | ||
# Use ffmpeg to transcode your desired video into IVF format | # Use ffmpeg to transcode your desired video into IVF format | ||
#* For example, if your video is a file named <code>input.mp4</code>, the command would be something like <code>ffmpeg -i "/path/to/input.mp4" -f ivf "/path/to/output. | #* For example, if your video is a file named <code>input.mp4</code>, the command would be something like <code>ffmpeg -i "/path/to/input.mp4" -f ivf "/path/to/converted.ivf"</code> | ||
#* If your source video resolution isn't the required you can also do <code>ffmpeg -i "/path/to/input.mp4" -f ivf -vf scale=<WIDTH>:240,fps=<FRAMERATE> "/path/to/converted.ivf"</code>, with "WIDTH" being either 400, 320 or 720 and "FRAMERATE" being between 1 and 60. | |||
# Use makebax to convert your <code>.IVF</code> file to a <code>.BAX</code> file | |||
#* Assuming you named your converted video <code>converted.ivf</code>, the command would be <code>makebax "/path/to/converted.ivf" "/path/to/output.bax"</code> | |||
# Copy <code>output.bax</code> to <code>SD:/bax/</code> on your console's SD card | |||
== Command Line Usage == | == Command Line Usage == |
Revision as of 21:55, 28 September 2022
This page is a work in progress. Notes:
|
makebax is a command-line utility for converting .IVF
video files into .BAX
animations to be used with BAX and played on a Nintendo 3DS.
Creating .BAX Animations
What You Need
- The latest release of makebax (It's in the
release.zip
file) - The latest release of ffmpeg installed on your computer
Instructions
- Open a terminal on your computer
- Use ffmpeg to transcode your desired video into IVF format
- For example, if your video is a file named
input.mp4
, the command would be something likeffmpeg -i "/path/to/input.mp4" -f ivf "/path/to/converted.ivf"
- If your source video resolution isn't the required you can also do
ffmpeg -i "/path/to/input.mp4" -f ivf -vf scale=<WIDTH>:240,fps=<FRAMERATE> "/path/to/converted.ivf"
, with "WIDTH" being either 400, 320 or 720 and "FRAMERATE" being between 1 and 60.
- For example, if your video is a file named
- Use makebax to convert your
.IVF
file to a.BAX
file- Assuming you named your converted video
converted.ivf
, the command would bemakebax "/path/to/converted.ivf" "/path/to/output.bax"
- Assuming you named your converted video
- Copy
output.bax
toSD:/bax/
on your console's SD card
Command Line Usage
makebax "input.ivf" "output.bax" [-s n] [-c l] [-b back_color] [-a "Author"] [-i "Info"]
Parameters enclosed in [ ]
are optional.
input.ivf
is the input IVF file path, the size must have a resolution of either 400x240 (top screen only), 320x240 (bottom screen only) or 720x240 (both screens side-by-side). Input must be an IVF container with a VP8/VP9 stream.output.bax
is the path to the BAX file that will be created.s
sets the block size. n is the number of frames that are processed per iteration. The higher the number, the more memory is used on runtime (and the less often disk accesses are required). Defaults to 48.c
sets the compression level. Should be between 1 (lowest) and 16 (highest). Defaults to 6.b
sets the background color.bg_color
should be the 16-bit integer representation of an RGB565 color. Defaults to zero (black). Refer to this site for more information.a
sets the Author string. It doesn't affect the player at all, but it's nice to include some metadata. Maximum length is 32 ASCII characters (or as much UTF-8 fits in there).i
is the same as above but for Information. Maximum length is 192 ASCII characters.
Notes
- IVF is a simple container for VP8/VP9 streams, unable to contain more than one stream. It was chosen as the input format due to it being both simple and straightforward to work with.
- Although it should be compatible with big endian platforms (PowerPC, Microblaze, etc) this has not been properly tested yet. Please report any issues regarding compilation/usage on big endian platforms.
- While having libav* support would be ideal, it's less than fit due to it's programming complexity (easy to make mistakes with) and labyrinth of dependencies (requires X11 libs, so it's unusable from servers, f.e.).
- For best performance, the block size should be an integer multiple of the number of available hardware threads (logical processors). This is why the default block size is 48: it's a multiple of the most common PO2 and MO6 multithread setups.
- BAX files should not surpass the 32MiB mark. makebax doesn't enforce this limit, but BAX does.