Skip to content

Commit

Permalink
removed prints, fixed spellings, general cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ProfOak committed Jun 29, 2015
1 parent 5542b07 commit edf2565
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
*swp
*pyc
test_imgs
8 changes: 4 additions & 4 deletions ascii.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ def artify(self, words="#", step=3):
MAX_W, MAX_H = self.from_pic.size
h = w = i = 0

# skip pixels by `step` amout and place characters around image
# skip pixels by `step` amount and place characters around image
while h < MAX_H:
while w < MAX_W:
# use a string as characters as the art characters
# use a string as the art characters
c = words[i]

# loop around
i = (i+1) % len(words)

draw.text((w, h), c, self.from_pic.getpixel((w, h)))
p = self.from_pic.getpixel((w, h))
draw.text((w, h), c, p)
w += step
h += step
w = 0
Expand Down
1 change: 1 addition & 0 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,4 @@ def main():

if __name__ == "__main__":
main()

0 comments on commit edf2565

Please sign in to comment.