inculi / Sue

A bot for iMessage (sue@robertism.com), Telegram (@ImSueBot), and Discord. Now in Elixir!
MIT License
27 stars 9 forks source link

Add image effects #12

Open Manwholikespie opened 4 years ago

Manwholikespie commented 4 years ago

FaceApp machine broke a while ago (still is, right? maybe I'll check again) so I figure it's time to do our own fun image stuff. This comes in three phases, methinks.

  1. Pre-defined filters chainable by separate messages. Imagemagick fun stuff, maybe some fun custom things of our own. We should be able to load up computational photography labs next semester. Called with, let's say, !i b&w <image>. Then Sue sends a response. Now, if a user does not supply an image, we should be able to instead feed in the last image the user (or their friend) sent, ooorrrr... here's the chain able part: the last image Sue sent. So, after Sue has sent back a black and white image, we can then do like !i meme bottomtext to add a text caption or something to it.
  2. Implement user data structures, including matrices, that can then be fed like !i %Identity <image> (just got this great idea: what if we let !wolf spit out matrices... bruh.)
    • reqs: start saving these as typed items in our DB (more on this later). If we do the !wolf thing, we'll need to examine function chaining... Hmm maybe save this part for 3?
  3. Inline-chainable, meaning we can perform multiple operations on the image before sending it. So, something like !i [meme bottomtext]*[b&w]. For starters, we'd probably just pass the resulting image matrix between the two functions instead of matmul, as we don't want to worry about resolving non-matrix operations (bottomtext) before reducing.
    • reqs: Because of the need for parentheses/brackets to group functions with parameters, there's a small chance we might actually need to start writing a parser for Sue, lol.
Manwholikespie commented 3 years ago

Partially done. Leaving up until we have the wolfram thing implemented, bc I think that's the coolest part of this idea.