A simple command line utility program to filter logs and generate timelapses for pxls.space. Designed for pxls.space users to explore their personal logs or generate pretty timelapses. Forgot where the logs are? They're right here. Your personal hashes are located on your profile page.
- Simple program settings
- Disable overwritting existing files
- Filter entries to file (Defaults to STDOUT)
- Via provided date (Format: %Y-%m-%dT%H:%M:%S%.f)
- Via colour index
- Via region (Format: x1,y1,x2,y2)
- Via actions (place, undo, overwrite, rollback, rollback-undo, nuke)
- Via user hash
- Render logs into timelapses or individual frames
- Customisable step (time passed between frames)
- Supports multiples file formats via the image crate
- Can pipe raw RGBA video data (e.g. ffmpeg)
- Supports multiple styles (e.g. heat, virgin, activity, etc)
- Can import custom palettes (.gpl, .aco, .csv, .txt (paint.NET)) including directly from pxls
- Crop to specified size
To get on track, seek the help argument. This will list basic arguments and display available subcommands. Alternatively, use on a subcommand to display arguments for the subcommand.
pxlslog-explorer.exe --help
pxlslog-explorer.exe filter --help
pxlslog-explorer.exe render --help
The filter subcommand is quite simple, follow the syntax hints for tricky filters such as "--after", "--before" and "--region". Be wary with many filters applied, it can be quite messy:
// Print straight to STDOUT
pxlslog-explorer.exe filter pixels_cXX.sanit.log
// Write to mypixels_cXX.log when color == 5
pxlslog-explorer.exe filter --color 5 pixels_cXX.sanit.log mypixels_cXX.log
// Write to mypixels2_cXX.log when equal to hash and action = undo
pxlslog-explorer.exe filter --action undo --user (insert hash here) pixels_cXX.sanit.log mypixels2_cXX.log
The render subcommand accepts a log file and produces frames in the desired format. However it can also produce a single complete frame. A palette can also be provided, either from raw json found here or palette files found here [.gpl, .aco, .csv, .txt (paint.NET)]. See the image crate for supported image formats.
The following styles are supported:
- Normal: Simulate pxls canvas
- Heat: Simulate pxls heat map
- Virgin: Simulate pxls virgin map
- Activity: Generate a heat map indicating most active pixels
- Action: Map pixel type to color (Magenta = Undo, Blue = Place, Cyan = Mod Overwrite, Green = Rollback, Yellow = Rollback undo, Red = Nuke)
- Milliseconds: Map pixel placement time within a second to a color, smooth regions indicate bot-like behaviour
- Seconds: Map pixel placement time within a minute to a color
- Minutes: Map pixel placement time within a hour to a color, gradient indicates placement direction
- Combined: Above methods combined into one, smooth rainbows indicate bot-like behaviour
- Age: Generate a brightness map, where darker pixels are older pixels
// Using background as source, produce a frame every 5 minutes in the PNG format
pxlslog-explorer.exe render -s pixels_cXX.sanit.log -d cXX.png --bg cXX.png --step 300000
// Or, produce a single frame
pxlslog-explorer.exe render -s pixels_cXX.sanit.log -d cXX.png --bg cXX.png --screenshot
// Or, use a different style
pxlslog-explorer.exe render -s pixels_cXX.sanit.log -d cXX.png --bg cXX.png --screenshot --type virgin
// You can also provide a custom palette.
pxlslog-explorer.exe render -s pixels_cXX.sanit.log -d cXX.png --bg cXX.png --screenshot --palette p10.gpl
// Additionally, crop frames without needing to modify logs or other shenanigans
pxlslog-explorer.exe render -s pixels_cXX.sanit.log -d cXX.png --bg cXX.png --screenshot --crop x y width height
Additionally, frames can be piped to other programs via STDOUT to produce a video. This has only been tested with ffmpeg. (Note that you need to specify the resolution)
pxlslog-explorer.exe render -s pixels_cXX.sanit.log --bg cXX.png --step 300000 | ffmpeg -f rawvideo -pixel_format rgba -video_size widthxheight -i pipe:0 ...
This program is certainly going to evolve as new use cases are discovered. As such, the intention is to accept feedback and adapt to what users desire to suit their needs. The scope of this program is intentially minimalistic so it can be expanded on or used as a foundation in other personal projects.
- Alternative output formats (.csv, etc)
- Statistics generation
- Ability to merge logs
- An actual GUI
- Probably not