It is currently 29 Nov 2021, 23:42

• Featuring Members' Works (Image Attachments) •
1: member
2: member
3: member
4: member
5: member

GIMP/GL:  Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  🡆 Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP
Sponsored content for World Food Program

Color Chips Plug-in

Share your Python Fu Scripts/plug-ins for GIMP here
tim
GL Blogger
1st Place
5623 Post(s)

Color Chips Plug-in

Post#1 by tim » 04 Feb 2019, 20:46


This plug-in is very simple. It converts an RGB image to indexed mode of specified number of colors.
Then selects each color and paints a square chip (same area as pixel count of color selected).
It's quite dumb, it doesn't care about overlapping areas.
But the result is random enough to be unique from one run to the next but still gives chips that represents colors of original image.
This plug-in is highly experimental.
colorchips.py #
(2.97 KiB) Downloaded 146 times
colorchips.py #
version 2. Fixed bug for Issabella
(3.05 KiB) Downloaded 131 times
colorchips.py #
version 3. Color chips on separate layers (requested by Issabella).
(3.12 KiB) Downloaded 215 times
Plug-in Menu Location: Python-fu/Color chips...

Instructions:
1. Open an image you'd like to make color chips of.
2. Run Plug-in (Python-fu/Color chips...). Choose number of colors/chips then click OK to run.
3. That's it. You'll end up with a new image (indexed mode) with a layer on top of the chips drawn. You can then easily change the background layer if you wish.
Sample results:
color_chips_mona_lisa.jpg
color_chips_mona_lisa.jpg # (81.79 KiB) Viewed 3235 times (Thumbnail | Recognize | Sq Tile | LNFI)
color_chips_mona_lisa_white_background.jpg
color_chips_mona_lisa_white_background.jpg # (33.06 KiB) Viewed 3235 times (Thumbnail | Recognize | Sq Tile | LNFI)
color_chips_picasso_guitarist.jpg
color_chips_picasso_guitarist.jpg # (28.4 KiB) Viewed 3235 times (Thumbnail | Recognize | Sq Tile | LNFI)
aka Tin
World Food Program | Good Deeds Forum

         

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#2 by Issabella » 05 Feb 2019, 07:17


Tin, this plug-in yours is very interesting. I like it. I'll play with it. Thanks a lot.
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#3 by Issabella » 05 Feb 2019, 08:35


I did the first try, Tin and I got this message.
Attachments
error.jpg
error.jpg # (47.47 KiB) Viewed 3205 times (Thumbnail | Recognize | Sq Tile | LNFI)
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

tim
GL Blogger
1st Place
5623 Post(s)

Post#4 by tim » 05 Feb 2019, 16:52


@Issabella , Thanks for testing it.
Please try version 2.
aka Tin
World Food Program | Good Deeds Forum

         

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#5 by Issabella » 05 Feb 2019, 18:33


Tin, thanks but I don't get the squares with the different colours. Please, take a look at the attachment.
Attachments
The result.jpg
The result.jpg # (49.86 KiB) Viewed 3173 times (Thumbnail | Recognize | Sq Tile | LNFI)
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

tim
GL Blogger
1st Place
5623 Post(s)

Post#6 by tim » 05 Feb 2019, 19:33


That's odd not sure why that is can you try turning of bottom layer to see if anythign drawn at all on top layer.
aka Tin
World Food Program | Good Deeds Forum

         

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#7 by Issabella » 05 Feb 2019, 19:59


On the upper layer is empty, Tin. Nothing in the layer.
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

tim
GL Blogger
1st Place
5623 Post(s)

Post#8 by tim » 05 Feb 2019, 20:20


This is weird. I don't know why that is.
Please share you original image and number of colors used so that I can try it on my machine and possibly track down why that is.
aka Tin
World Food Program | Good Deeds Forum

         

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#9 by Issabella » 05 Feb 2019, 21:17


Thank you so much Tin. These are.
Attachments
Desktop.zip #
(305.84 KiB) Downloaded 117 times
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

tim
GL Blogger
1st Place
5623 Post(s)

Post#10 by tim » 06 Feb 2019, 00:15


So odd, I was able to get results.
Attachments
squirrel_issa.jpg
squirrel_issa.jpg # (45 KiB) Viewed 3144 times (Thumbnail | Recognize | Sq Tile | LNFI)
aka Tin
World Food Program | Good Deeds Forum

         


GIMP/GL:  Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  🡆 Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP

Post Reply New Topic
  • Similar Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 11 guests