vv9k / epick

Color picker for creating harmonic color palettes that works on Linux, Windows, macOS and web.
GNU General Public License v3.0
102 stars 2 forks source link

Export as glsl vec3[] #48

Open wrightwriter opened 2 years ago

wrightwriter commented 2 years ago

feature request.

wrightwriter commented 2 years ago

it'd be rly nice to be able to copy it to clipboard

vv9k commented 2 years ago

It should be possible by adding a custom format in the settings window and setting the clipboard format to it, something like vec3({r:.2} {g:.2} {b:.2}), but you would have to experiment to make it match your needs as I don't really know how glsl vec3 looks.

vv9k commented 2 years ago

Here is an example:

image

wrightwriter commented 2 years ago

oh, thanks, this is very cool! :) just wish it could copy to clipboard:

vec3[](
  vec3(.0,.0,.0),
  vec3(.0,.0,.0),
  vec3(.0,.0,.0)
);

It is copying the hex values 🤔 I'm wondering if I should code this for myself or it makes sense in epick itself.

vv9k commented 2 years ago

You mean exporting a whole palette of colors as this format? That is indeed not possible at the moment, only clipboard format of single color can be modified.

I think the way to proceed here is to add a way to define custom copy format for copying the whole palette so that users could define their own formats rather than wait for it to be merged into master.

I'll have a look into this after this weekend as I have no access to a computer.

vv9k commented 2 years ago

I have a working draft, gonna clean it up and probably merge soon.

image