Wallpaper generator

silentdude56k said...I don't know how you'd automate this on Macs (you might use cron, not sure), but it's a little more interesting to get a wallpaper update schedule going on Windows; I'll look into it since I have some free time right now.
 Windows has an `at` command fairly similar to the Unix version (which doesn't exist on my Debian box. Interesting...); it's tied right into the scheduled tasks service but it's not as ridiculous to deal with. It will cause a cmd window to pop up every time the task is performed, though. I think you need to use Visual Basic to avoid that?

Manpage: http://ss64.com/nt/at.html

Update:

I think I may have figured out how freetype works: :D

I originally had some problems with converting from utf8 to utf32, but as can be seen bellow I'm now able to render a character based on a utf8 input file. Next step is to replace the SDL rendering functions with the freetype ones.



Updated linuxversion

The linux version has been updated to "0.5"
It now has support for commandline options, start program with --help to get a list.

Download: https://dl.dropbox.com/u/412571/wanikaniwallpaper-linux-0.5.tar.gz

Sweet.

akranis said...

Updated linuxversion

The linux version has been updated to "0.5"
It now has support for commandline options, start program with --help to get a list.

Download: https://dl.dropbox.com/u/412571/wanikaniwallpaper-linux-0.5.tar.gz
 Updated the unofficial Windows build to version 0.5.

Download: https://docs.google.com/file/d/0B45KzpxyN8ncUlpDQU5NN0VhNkk/edit?usp=sharing
VirusTotal: https://www.virustotal.com/en/file/01867dda321af1e08e729fa9517fcda93f653b8e042cbe82b605e82095d94b12/...

1.0 Woo!

1.0 versions are now available for linux and windows. :D

Basic usage:
Open config.ini and enter your api-key.

Options available to set from config or commandline:

  -k [ --apikey ] arg                 API key

  -w [ --width ] arg (=1920)          Width of wallpaper

  -h [ --height ] arg (=1080)         Height of wallpaper

  -o [ --out ] arg (=out.png)         Output filename

  -f [ --font ] arg (=ipag.ttf)       Relative or absolute font filepath

  --margin-left arg (=0)              Space to leave blank to the left

  --margin-right arg (=0)             Space to leave blank to the right

  --margin-top arg (=0)               Space to leave blank to the top

  --margin-bottom arg (=0)            Space to leave blank to the bottom

  --color-background arg (=0x000000)  Color for background

  --color-unseen arg (=0x303030)      Color for unseen characters

  --color-apprentice arg (=0xDD0093)  Color for apprentice characters

  --color-guru arg (=0x882D9E)        Color for guru characters

  --color-master arg (=0x294DDB)      Color for master characters

  --color-enlightened arg (=0x0093DD) Color for enlightened characters

  --color-burned arg (=0xFFFFFF)      Color for burned characters

  --color-error arg (=0xFF0000)       Color for error'ed characters
1 Like

This is awesome! Great job! :smiley:

1.0 works like a charm. Thank you very much!

Bravo. Excellent idea. Great way to see progress

update 1.1

Update 1.1 brings further stability by explicitly handling connection and api errors.

If the api call fails in any way, no image will be generated, where before all characters were marked as unseen. 

I also noticed that not all characters in wanikani exists in my order file. If you are of a high level, please make sure you're not missing any characters. This can be done by running the program from a commandline (win+R, then open cmd.exe), where it will list all characters it couldn't find in my file. Then please post that list here and I'll update the order file.

You can easily check that list by querying each level via the API to access all characters from wanikani and check against the order file.

Ah. That’s what I get for not reading the API properly :stuck_out_tongue: I thought I was only able to access the characters up to my current level.

  • Kanji from WaniKani not found in file: 贅, utf32: 8d05
  • Kanji from WaniKani not found in file: 枕, utf32: 6795
  • Kanji from WaniKani not found in file: 綺, utf32: 7dba
  • Kanji from WaniKani not found in file: 鍋, utf32: 934b
  • Kanji from WaniKani not found in file: 醤, utf32: 91a4
  • Kanji from WaniKani not found in file: 噌, utf32: 564c
  • Kanji from WaniKani not found in file: 丼, utf32: 4e3c
I was expecting a lot more actually. Anyway, going to bed now, so I’ll fix these last characters tomorrow.

This looks great! Thanks Mr. Turtle :slight_smile:

SUUUUPER COLOURFULL!! I don’t have any burned items yet, but they’ll be yellow :slight_smile:

I really wanted to try this out, but apparently there are no instructions. I downloaded the 32bit file, opened the config.ini and entered in my API key, but when I ran it, the command prompt said ‘unable to parse API key, is this json?’ 

jacobjapan said... I really wanted to try this out, but apparently there are no instructions. I downloaded the 32bit file, opened the config.ini and entered in my API key, but when I ran it, the command prompt said 'unable to parse API key, is this json?' 
 Are you sure you put the key in the right spot with no spaces or such? I'll check back here when I have access to my desktop with my copy on it, and I'll be able to post my .cfg

From what program did the utf8.h come from that you are using in order.cpp?  Trying to compile it on my linux since the download won’t ungzip.

aramilmoonmist said...
jacobjapan said... I really wanted to try this out, but apparently there are no instructions. I downloaded the 32bit file, opened the config.ini and entered in my API key, but when I ran it, the command prompt said 'unable to parse API key, is this json?' 
 Are you sure you put the key in the right spot with no spaces or such? I'll check back here when I have access to my desktop with my copy on it, and I'll be able to post my .cfg
 I'm getting the same problem

I was just thinking about creating a desktop background and Xing out Kanji I know and such with photoshop and changing it all when I’ve leveled! I’m glad I ran across this thread! Saves me a lot of work :smiley:

yako500 said...
aramilmoonmist said...
jacobjapan said... I really wanted to try this out, but apparently there are no instructions. I downloaded the 32bit file, opened the config.ini and entered in my API key, but when I ran it, the command prompt said 'unable to parse API key, is this json?' 
 Are you sure you put the key in the right spot with no spaces or such? I'll check back here when I have access to my desktop with my copy on it, and I'll be able to post my .cfg
 I'm getting the same problem

 I had the same problem but looked at the config closely and figured out to delete a couple quotes I think? T'was a while ago.
Here's what mine looks like for the first little bit, just follow my example:

apikey=2b50a5fthisismykeye5d3db53f width=1920