Use PNG files for tests and examples
These are much smaller than the previous BMP files Fixes https://github.com/libsdl-org/SDL/issues/14159
This commit is contained in:
@@ -71,16 +71,16 @@ everything consistent. You can ignore it.
|
||||
|
||||
This is how Ryan is doing it currently.
|
||||
|
||||
- `rm -f frame*.bmp`
|
||||
- `rm -f frame*.png`
|
||||
- Temporarily add `#include "../../save-rendering-to-bitmaps.h"` after any SDL
|
||||
includes in the example program.
|
||||
- Launch the example app, interact with it, let it run for a few seconds, quit.
|
||||
- This will dump a "frameX.bmp" file for each frame rendered.
|
||||
- This will dump a "frameX.png" file for each frame rendered.
|
||||
- Make a video in webp format from the bitmaps (this assumes the bitmaps were
|
||||
stored at 60fps, you might have to tweak).
|
||||
|
||||
```bash
|
||||
ffmpeg -framerate 60 -pattern_type glob -i 'frame*.bmp' -loop 0 -quality 40 -r 10 -frames:v 40 onmouseover.webp
|
||||
ffmpeg -framerate 60 -pattern_type glob -i 'frame*.png' -loop 0 -quality 40 -r 10 -frames:v 40 onmouseover.webp
|
||||
```
|
||||
|
||||
You might need to start in the middle of the video, or mess with quality or
|
||||
@@ -89,6 +89,6 @@ This is how Ryan is doing it currently.
|
||||
pngquant for massive file size reduction without any obvious loss in quality:
|
||||
|
||||
```bash
|
||||
convert frame00000.bmp cvt.png ; pngquant cvt.png --output thumbnail.png ; rm -f cvt.png
|
||||
convert frame00000.png cvt.png ; pngquant cvt.png --output thumbnail.png ; rm -f cvt.png
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user