I tried implementing it based on your comment so thanks for the tip! I don't have really have mathematical background or experience so it was kinda fun doing it. But the program is pretty slow and it gives me different (but what looks like somewhat similar/correct) color swatches back on every run. Don't know if I understand k-means incorrectly or my implementation is flawed; probably both ;)
Love the series. To any developers that want play with the media cut... the bug that he fixes consistenly produces a muted palette. Also, generating the complementary color swatch creates a lovely contrast (so far)
As soon as I saw the initially generated swatch, I could see that there was obviously something wrong. There's a large swathe of greens in the middle of the picture which were not represented in the resulting palette.
Paul, so far how different has been for you doing basic scripting tasks in node.js vs python, the fact that python has a big standard library and for node.js you need to install modules. Also the programming model of node.js, you have EventEmmiter, Stream, Buffer, I feel a bit hard to understand how all interconnects.
Kevin Rodriguez Roman great question. To be honest I keep things really simple, though this time I am using DustJS for templating because it supports async templates, i.e. you can use Promises. Lots of people know way more than me about Node. Python vs Node? I dunno, both have up and downsides.
Side note: A simpler but less efficient algorithm for generating color palettes is k-means clustering. It’s a good exercise to implement :)
attentioncore yeah Surma. hurry up...
I tried implementing it based on your comment so thanks for the tip! I don't have really have mathematical background or experience so it was kinda fun doing it. But the program is pretty slow and it gives me different (but what looks like somewhat similar/correct) color swatches back on every run. Don't know if I understand k-means incorrectly or my implementation is flawed; probably both ;)
It certainly iess less efficient but the thing is to prove that there's more out there than k-means for generating color palettes!
Love the series. To any developers that want play with the media cut... the bug that he fixes consistenly produces a muted palette. Also, generating the complementary color swatch creates a lovely contrast (so far)
Google is behind the cutting edge. I was doing this back in the late 80s.
Another Paul Lewis video, another opportunity to feel like a novice again lol. Keep 'em comin! This series is off to a great start.
Great video, Paul, perfect for my median cut exercise!
every video is full of such sheer knowledge....
Link to the repo or didn't happen.
The repo can be found on github : github.com/paullewis/sample-media-pwa
This is genially good! Really interesting series
As soon as I saw the initially generated swatch, I could see that there was obviously something wrong. There's a large swathe of greens in the middle of the picture which were not represented in the resulting palette.
So, I'm not the only one who make mistakes while copy&pasting!
What a relieve...
May I suggest putting a link to the Wikipedia article next to the const calcLuminance formula? As a code comment
What are the Node packages I need to install through out the tutorials
Paul, so far how different has been for you doing basic scripting tasks in node.js vs python, the fact that python has a big standard library and for node.js you need to install modules. Also the programming model of node.js, you have EventEmmiter, Stream, Buffer, I feel a bit hard to understand how all interconnects.
Kevin Rodriguez Roman great question. To be honest I keep things really simple, though this time I am using DustJS for templating because it supports async templates, i.e. you can use Promises. Lots of people know way more than me about Node. Python vs Node? I dunno, both have up and downsides.
Q: why is DEFAULT_DEPTH a getter method and not just a property? Read-only, or anything else?
Hello some have the code of this tutorial?
Never before have I felt more like a rubber duck…
Yayyy day #3! :D
am i the only one that had to pause the code section to understand the quantizing bit and still didnt understand it:(
Reggie_thoughts have a read of the Wikipedia article on Median Cut. It explains it really well.
Nice video :)
hash four where are you? :)