Skip to content

Instantly share code, notes, and snippets.

@onyxfish
Created May 31, 2013 18:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save onyxfish/5686902 to your computer and use it in GitHub Desktop.
Save onyxfish/5686902 to your computer and use it in GitHub Desktop.
Glyph definitions for http://she-works.tumblr.com/
var BITMAPS = {
BIRD_OF_PREY: [
[0,0,0,0,0,0,0,0,0],
[0,0,1,1,1,1,1,1,0],
[0,1,0,1,0,0,0,0,0],
[0,1,1,1,0,0,0,0,0],
[0,1,0,0,1,0,0,0,0],
[0,1,0,0,0,1,1,1,0],
[0,1,0,0,0,1,1,1,0],
[0,1,0,0,0,1,1,0,0],
[0,0,0,0,0,0,0,0,0]
],
TRIPPY_TRIANGLES: [
[0,0,0,0,0,1,0,0,1,1,1,1,1,0,0,1,0,0,1,1,1,1,1,0,0,1,0,0,1,1,1,1,1,0,0,1,0,0,0,0,0],
[0,0,0,0,1,1,1,0,0,1,1,1,0,0,1,1,1,0,0,1,1,1,0,0,1,1,1,0,0,1,1,1,0,0,1,1,1,0,0,0,0],
[0,0,0,1,1,1,1,1,0,0,1,0,0,1,1,1,1,1,0,0,1,0,0,1,1,1,1,1,0,0,1,0,0,1,1,1,1,1,0,0,0]
],
SWOOPS: [
[0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[0,0,0,1,1,0,0,0,0,0,0,0,0,1,0,0,1,0,1,0,0,1,0,0,0,0,0,0,0,0,1,1,0,0,0],
[0,1,1,0,0,1,1,1,1,0,0,0,0,0,0,0,1,0,1,0,0,0,0,0,0,0,1,1,1,1,0,0,1,1,0],
[1,0,0,0,1,0,0,0,0,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,0,0,0,0,1,0,0,0,1],
[1,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,1],
[0,1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,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],
[1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]
]
};
var GLYPH_SETS = {
'no-border': [],
'space-invaders': [{
bitmap: BITMAPS.INVADERS,
align: 'center',
valign: 'top',
grid_offset_x: 0,
grid_offset_y: 1,
invert: false,
vinvert: false
},
{
bitmap: BITMAPS.DEFENDERS,
align: 'center',
valign: 'bottom',
grid_offset_x: 0,
grid_offset_y: 1,
invert: false,
vinvert: false
}],
'flower-corner': [{
bitmap: BITMAPS.BIRD_OF_PREY,
align: 'left',
valign: 'top',
grid_offset_x: 1,
grid_offset_y: 1,
invert: false,
vinvert: false
}, {
bitmap: BITMAPS.BIRD_OF_PREY,
align: 'right',
valign: 'top',
grid_offset_x: 1,
grid_offset_y: 1,
invert: true,
vinvert: false
}, {
bitmap: BITMAPS.BIRD_OF_PREY,
align: 'right',
valign: 'bottom',
grid_offset_x: 1,
grid_offset_y: 1,
invert: true,
vinvert: true
}, {
bitmap: BITMAPS.BIRD_OF_PREY,
align: 'left',
valign: 'bottom',
grid_offset_x: 1,
grid_offset_y: 1,
invert: false,
vinvert: true
}],
'swash-border': [{
bitmap: BITMAPS.SWOOPS,
align: 'center',
valign: 'top',
grid_offset_x: 0,
grid_offset_y: 1,
invert: false,
vinvert: false
}, {
bitmap: BITMAPS.SWOOPS,
align: 'center',
valign: 'bottom',
grid_offset_x: 0,
grid_offset_y: 1,
invert: true,
vinvert: true
}],
'triangle-border': [{
bitmap: BITMAPS.TRIPPY_TRIANGLES,
align: 'center',
valign: 'top',
grid_offset_x: 0,
grid_offset_y: 1,
invert: false,
vinvert: false
}, {
bitmap: BITMAPS.TRIPPY_TRIANGLES,
align: 'center',
valign: 'bottom',
grid_offset_x: 0,
grid_offset_y: 1,
invert: false,
vinvert: true
}]
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment