SoF screenshot tools

Tools to rename and convert SoF screenshots.

Web browsers are unable to display SoF screenshots, because they are in TGA format. This sof45.tga SoF screenshot will be used in the conversion examples below.

ss_new.py

Rename and convert new SoF screenshots. The script searches for files named 'sof??.tga', converts them to PNG and renames them to 'sof_????-??-??_??????.png'. Don't delete these files, because they can be used to create other images with different sizes or formats.

sof_2011-08-26_225935.png: PNG version of sof45.tga
sof_2011-08-26_225935.png

ss_convert.py

The script searches for files named 'sof_????-??-??_??????.png' and converts them to different sizes or formats named 'convert_*.png'. You can re-run the script to generate these images again. This is just an example script. You should change it to make it create the images you need.

convert_ts_sof_2011-08-26_225935.png: Same as sof_2011-08-26_225935.png but with a timestamp at the bottom
convert_ts_sof_2011-08-26_225935.png

convert_160x120_2011-08-26_225935.png: Resized to 160x120 thumbnail
convert_160x120_2011-08-26_225935.png

convert_ts_160x120_2011-08-26_225935.png: Resized to 160x120 thumbnail with a timestamp at the bottom (creation of this image has been disabled in ss_convert.py)
convert_ts_160x120_2011-08-26_225935.png

convert_640x480_2011-08-26_225935.png: Resized to 640x480
convert_640x480_2011-08-26_225935.png

convert_ts_640x480_2011-08-26_225935.png: Resized to 640x480 with a timestamp at the bottom
convert_ts_640x480_2011-08-26_225935.png

convert_scoreboard_2011-08-26_225935.png: Only the scoreboard
convert_scoreboard_2011-08-26_225935.png

convert_ts_scoreboard_2011-08-26_225935.png: Only the scoreboard with a timestamp at the bottom
convert_ts_scoreboard_2011-08-26_225935.png

convert_debug_2011-08-26_225935.png: Image used for debugging scoreboard detection (creation of this image has been disabled in ss_convert.py). Scoreboard detection should work for all gamemodes if you're using the original english, german or french string packages.
convert_debug_2011-08-26_225935.png

Note that all timestamps are in UTC. Using different timezones would be confusing.

ss_sof_run.cmd

Starts SoF and after quitting SoF, renames and converts all new screenshots

ss_png2jpg.cmd

Convert PNG files to JPG. JPG is a really bad format, but sometimes websites don't allow you to upload PNG files.

Installation

  1. Install the SoF screenshot scripts
    • Download the scripts from here
    • Install in your SoF installation directory (you'll figure it out)
  2. Install Python 2.7.x or 3.2.x
  3. Install ImageMagick
  4. Copy ImageMagick convert.exe and identify.exe to your screenshot directory
    • Copy convert.exe and identify.exe from the ImageMagick installation directory (C:\Program Files\ImageMagick-6.7.4-Q16\) to your SoF screenshot directory (C:\...\user\scrnshot\)
  5. Optional: Edit your SoF shortcut to automatically convert screenshots after quitting SoF
    • Change the shortcut to start SoF: Replace 'SoF.exe' with 'ss_sof_run.cmd'

Please let me know if you get a Windows error message like 'ImageMagick Studio library and utility programs has encountered a problem and needs to close. We are sorry for the inconvenience.'. I may have a workaround for this problem.

Links