Image Generation from the Ground Up
I’m extremely excited to announce the completion of a project that has basically sucked down every waking hour since I started it several weeks ago. And that is this: a complete overhaul of the Mycena Cave Image Generation code. This is the code that underpins all Mycenian images, geness images, avatar images, the magic puddle, and so on.
What’s new?
Previously we used a library called ImageMagick to perform layering operations, hue shifts, and so on. That itself was an improvement in speed and image quality over our initial work and has served us well since December of 2013, but has had its own fair share of warts. This time we’re eschewing libraries altogether in favor of getting our hands dirty and working the images manually. This has two benefits
Speed
First, speed: this new thing is fast. Blazingly fast. I wrote it from the ground centered around getting an image out the door as fast as computationally possible, and it paid off. On average, the new system will generate a Mycenian image four to five times faster than what we’ve been using so far: a Mycenian with a reasonable number of items equipped might previously have taken around 2.5 seconds to render can now be generated in about 0.6 seconds. This is particularly noticeable in the “Manage Pet” interface, when you’re sorting, enabling, or disabling layers. Each change you make needs to re-load the image, which would take several seconds before Mycena Cave could even begin to transmit it to you. This interface will now be a lot snappier. Flexibility
By avoiding shunting the image processing to pre-existing software and performing image operations ourselves (as it turns out, there is a surprising amount of interesting math going on even in simple operations like “put one layer on top of another”), we gain the flexibility of being able to do… well… anything we want. As a prime example, consider shifting colors. Years ago when we first introduced the Driftshroom (which performs a hue shift on your Mycenian), we meant it as kind of a joke item — a kind of “look what we can do!”. We were so amused by the fact that we could that we never really stopped to think whether we should. While it can result in some neat effects, the results often end up looking garish, inverting shadows and highlights and generally looking “wrong”.
We know many of you love your current drifts, so we will be keeping the current Driftshroom mechanic — your drifted pets aren’t changing out from under you. We haven’t yet determined exactly how we’ll release this new color shifting mechanic, but we’re very pleased with the expanded flexibility of our image generation, and you can expect to see the new color shifting (as well as potentially other cool features) to become available soon. All in all, the new image generation code will help with image loading speed and increase flexibility of image manipulations of pets which will open new possibilities of making your pet more unique. We hope you’ll enjoy the updates!
Posted 01/18/20, edited 01/18/20
|
|
How interesting. I have to say, I never really noticed how differently the drifted pets appeared detail-wise, even being one so addicted to drifters as I am. I just kinda figured that the details lost were because the colors were too similar and that I’m not good at distinguishing those details. If this turns into having retro vs new drifty capability on pets, I’d be so down for that. There are drifts I don’t want to change and ones I’d love to see with the new rendering. Although if we did have a way to preview how differently the new look would be on drifted pets via the Puddle, I’d appreciate that before anything changed. I’m assuming that this would be so? I’m looking forward to the new changes, regardless.
Posted 01/18/20
|
|
Oh my GOOOOOSSSSSHHHH I am gonna be nugget poor forever........... the Magic effects are BEAUTIFUL and I am so curious to play with the effects. Can it be added to Magic Puddle at some point, even if you haven’t decided how to introduce the effect yet? I really really really wanna play with how my pets are gonna look!!
Posted 01/18/20
|
|
Sooo… Some of my pets are displaying in grayscale currently, but only when I click to their individual profiles (they appear normal on my main profile page.) Is that part of this? (None of the ones affected have drift/gloom shrooms applied.) Edit: Affected pets are Illociel, Avery, and Naia Oh! And Silhouette is showing up in grayscale on her profile and on my main profile. :P
Posted 01/19/20, edited 01/19/20
|
|
In all seriousness, this update is really neat, even if it does make my life a little more difficult. I’d noticed that some of the coats just drifted way more brightly than the base coat, so I’m glad that’s being addressed E: I’m apparently experiencing the same problems as WindyFox, because my avatar isn’t meant to be grey.
Posted 01/19/20, edited 01/19/20
|
|
Thank you for keeping the original mechanic for now. I have a hard time imagining what other drifts would look like under the “magic” version compared to normal drifts (it looks like it does something like darken the outlines more or apply slightly different shifts to the base/highlights/shadows?) and appreciate being given a bit more options to choose with teh changes. I’m also stoked that dressup is faster!
Posted 01/19/20
|
|
Jacq Hyasynthetic it’s basically performing transformations into and out of a variant of CIELAB called CIELCH — the basis is that unlike RGB/HSL/HSV/CMYK/etc., changing the chroma or hue should not alter the perceived luminosity. Some art programs can perform this transformation as well (I believe in Photoshop it is referred to as ‘lab mode’), but if you need the actual formulae you can find them here — just make sure you first convert the RGB images into linear-RGB or you’re going to have a bad time :| The image generation code currently treats each Mycenian as its own colorspace entity — currently any drifty items equipped to a Mycenian will drift in the same manner.
Posted 01/19/20, edited 01/19/20
|
|
Erm. Sprouts seem to be kind of broken right now. Mine is showing as a broken image link. D:
Posted 01/19/20
|
|
Ooh, interesting! I’ll have to do some more research on that later. I’ve managed to get close-enough-for-guide-purposes through the use of a bit of patience and colour overlay layers, which is at the very least a facsimile of the new system (Keeping the luminosity of whatever’s below it, in this case, an unmodified version of the pet.) It was consistent on all the pets I tested it on, and this way, I don’t have to mess around with formulae I don’t understand.
Posted 01/19/20
|
|
If anyone is wondering how to preview on their own, here are two methods to do it! Unfortunately I don’t believe CSP or SAI 1/2 have the capability to do the new magic previews, but Glitch just figured out how to preview them on GIMP, which is free (and also super simple)! Photoshop 1. Change to Lab Color by going to Image > Mode > Lab Color GIMP 1. Go to Colors > Hue-Chroma and use the Hue slider
Posted 01/19/20, edited 01/19/20
|
|
Uhm my avatar background is currently somehow one I don’t even own? I didn’t even change it from black so idk what’s going on. Edit: actually it’s kind of random. I had seen it with the rainbow one at first but after drifting and glooming and then undoing the drift it’s a different avatar background. I don’t think I own this one either though. Edit 2: Drifting and glooming Vera just broke her geness image. Edit 3: After a spate of further testing with Briar, I’ve determined that Briar and Aucos’ geness image remains broken even after I swap her back to normal for either or both values. On the bright side all that testing made the avatar go back to the right background. I did take screenshots though if you need to see them. Edit 4: So uhm does by any chance the changes mess with the shading because I think Briar looks a touch more…saturated ish? Than she used to. Edit 5: glitch did you do something to the shading and highlight layers?
Posted 01/19/20, edited 01/19/20
|
|
Lala your geness image was broken because it turns out all geness images were broken for a couple hours last night. That’s been fixed :) There have been no changes to the current drift mechanic, saturation, or any layers. I haven’t yet gotten to the bottom of the mystery avatar background switching yet, but you aren’t the only person this has happened to so hopefully we’ll sort it out relatively quickly.
Posted 01/19/20
|