It is currently 19 Jan 2020, 05:07


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

Generate Cross Stitch pattern and DMC thread information Script for GIMP

Share your Python Fu Scripts/plug-ins for GIMP here
Post Reply
tim
GL Blogger

Generate Cross Stitch pattern and DMC thread information Script for GIMP

Post#1 by tim » 23 Mar 2017, 21:03


Generate Cross-Stitch Pattern GIMP 2 Banner/

With the below script, you can generate your own cross-stitch patterns for free (in GIMP).

I was watching people cross stitching on twitch.com and decided to do a plug-in/script for people to use to cross-stitch.
Use this as an alternative of programs like Winstitch (if you can't afford it). Hope you guys like it. If you find it useful, I'd love to hear from you about it. Also there's a Beads pattern script which is an a variation from this script intended for perlers.

Download
cross_stitch_tt.zip
zipped .py file (unzip, put in your GIMP's /plug-ins/ folder) (GIMP 2.8)
(10.2 KiB) Downloaded 469 times
Download
cross_stitch_tt (2).zip
version 2 (GIMP 2.8) (saves each thread selection to channels, so that we are able to run "Cross Stitch DMC replace colors" script after adding DMC code to end of layer names) So that the process is still automatic but can manually change one or more colors afterwards.
(10.34 KiB) Downloaded 378 times
(for version 2, if you wish to manually change one or more DMC colors after the automatic process, you can use "Cross Stitch DMC replace color" script found here --> http://gimplearn.net/viewtopic.php?f=3&t=520)
cross_stitch_tt(2.5).zip
version 2.5 - Added Delta-E color matching method (GIMP 2.8) Delta-E is based on Human Vision Perception so it's superior to other methods of matching colors
(10.8 KiB) Downloaded 125 times
cross_stitch_tt(2.6).zip
version 2.6 - for GIMP 2.8 Added stitch count to thread info (requested by yellowzip)
(11.01 KiB) Downloaded 84 times
cross_stitch_tt(3).zip
version 3 - Scripted and Tested for GIMP 2.10 (Tested on Linux [Ubuntu] GIMP flatpak installation)
(10.61 KiB) Downloaded 193 times
cross_stitch_tt(4).zip
version 4 - Added Delta-E color matching method (GIMP 2.10) Delta-E is based on Human Vision Perception so it's superior to other methods of matching colors
(11.17 KiB) Downloaded 362 times
cross_stitch_tt(5).zip
version 5 - for GIMP 2.10.X Added stitch count to thread info (requested by yellowzip)
(11.3 KiB) Downloaded 144 times
cross_stitch_tt.py
version 6 - for GIMP 2.10.X. Converted from UTF-8-BOM to UTF-8 encoding so that it would run on Windows.
(35.67 KiB) Downloaded 139 times
cross_stitch_tt.py
version 7 - for GIMP 2.10.X. Use symbols instead of Hex Digits. Looks nicer and easier to identify symbols.
(37.22 KiB) Downloaded 38 times
cross_stitch_tt.py
version 8 - for GIMP 2.10.X. Outputs dimension of pattern at bottom Thread Info image (for reference later).
(37.74 KiB) Downloaded 36 times
cross_stitch_tt.py
version 9 - for GIMP 2.10.X. Fix total stitch count.
(37.89 KiB) Downloaded 39 times
cross_stitch_tt.py
version 10 - for GIMP 2.10.X. Print out sizes in inches and centimeters on for aida 14,16 and 18 count (at bottom of thread info image)
(39.6 KiB) Downloaded 39 times
cross_stitch_tt.py
version 11 - for GIMP 2.10.X. Added interpolation option for scaling (as sometimes "None" looks better than "Cubic" depending on image/taste).
(39.87 KiB) Downloaded 47 times
cross_stitch_tt.py
version 13 - for GIMP 2.10.X. Some enhancement and fix of blank 15th symbol.
(43.05 KiB) Downloaded 40 times
cross_stitch_tt.py
version 14 - for GIMP 2.10.X. Fixed centimeter size estimation bug.
(43.08 KiB) Downloaded 85 times
cross_stitch_tt.py
version 15 - for GIMP 2.10.X Replace blank symbols with visible symbols bug fix.
(43.13 KiB) Downloaded 155 times
Script Menu location: Python-Fu/Cross Stitch...

Script Options
gimp_cross_stitch_options.jpg
gimp_cross_stitch_options.jpg (111.77 KiB) Viewed 8419 times
Instructions:
1. Open up any image, with an active/selected layer.
2. Run Script (Python-Fu/Cross Stitch..). Adjust options.
3. Wait for script to run (it'll show progress bar).
4. After script is done you should see 2 new images (1 is the cross-stitch pattern, the other is DMC thread information [also used to name the layers in the cross-stitch pattern image).
5. Enjoy cross-stitching! If it works for you, I'd love to see your final real life cross-stitches (share on this thread if you'd like).

Sample original:
gimp.png
gimp.png (133.4 KiB) Viewed 8419 times
Sample cross stitched pattern
gimp_cross_stitch_pattern.jpg
gimp_cross_stitch_pattern.jpg (3 MiB) Viewed 8419 times
Sample thread info image
gimp_cross_stitch_thread_info.jpg
gimp_cross_stitch_thread_info.jpg (91.21 KiB) Viewed 8419 times
Screen shot of viewing cross-stitch pattern while in GIMP.
gimp_cross_stitch_pattern_screenshot.jpg
gimp_cross_stitch_pattern_screenshot.jpg (857.5 KiB) Viewed 8419 times
Note: there was a white layer of 30 opacity added over top of stitch pattern to allow stitch symbols to be visible (even when over black). If you wish you could toggle this layer's visibility off.
Sample pattern with white layer turned off.
gimp_cross_stitch_pattern_with_white_layer_turned_off.jpg
gimp_cross_stitch_pattern_with_white_layer_turned_off.jpg (3.06 MiB) Viewed 8418 times
Video clip of me using the script in GIMP


GIMP 2.10 screenshot (version 3 of script)
2_10_screenshot_of_cross_stitch_tt_run.jpg
2_10_screenshot_of_cross_stitch_tt_run.jpg (96.41 KiB) Viewed 6269 times
While on cross-stitching related topic, you might be interested in http://gimplearn.net/viewtopic.php?f=5&t=518&p=3347
Or if you want to be able to manually choose your DMC for each color instead of this automatic method: http://gimplearn.net/viewtopic.php?f=3&t=520
aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
1

Pat625
Tutorial Creator

Post#2 by Pat625 » 25 Mar 2017, 00:42


That looks like a really neat script, Tin! I did not get into cross stitching as never really had time for it. However, If I ever do, I'll remember your script for certain.
0

tim
GL Blogger

Post#3 by tim » 26 Mar 2017, 16:08


LadyAshleen on twitch said that right off the bat, she would suggest that she wants the ability to change individual pixels.
As GIMP is already a great image editor, this script is meant to be run on an already finished image so any edits should be done before using script.

I suggested that what she should do is before generating the cross stitch pattern:
  • Edit/Work on her image as pixel art. Like for example if she wants a stitch pattern that is 100 stiches wide, she should edit scale the image down/up to 100 pixel wide
  • Then Image->Mode->Indexed (enter number of colors she wants).
  • Continue to work in indexed mode as pixel art (zoomed in)
  • Then once she's happy, she can convert it back to RGB mode by going Image->Mode->RGB
  • Now that the image is ready, run script to generate cross stitch pattern (on this ready result)
.
aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
0

Issabella
Script Tester

Post#4 by Issabella » 27 Mar 2017, 13:57


Tin, you have created a very useful great filter. I love it. :yay_yay_purple: :gimp_clap:
Issabella

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

tim
GL Blogger

Post#5 by tim » 30 Mar 2017, 16:46


aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
0

No avatar
berserker
Forum Member

Post#6 by berserker » 09 May 2017, 04:41


Hi
I just downloaded your script and placed in the plug-ins directory for GIMP(2.8), but it is not showing up in the menus( after restarting GIMP).
Before I go off poking around in the code, are you aware of any problems/solutions?

I'm using OSX 10.12.4 and GIMP 2.8 and have the script at ~/Library/Application Support/GIMP/2.8/plug-ins/

Cheers
GIMP Learn rocks...
1

tim
GL Blogger

Post#7 by tim » 09 May 2017, 05:36


I think if you're on linux you have to make the .py executable.
aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
0

No avatar
berserker
Forum Member

Post#8 by berserker » 09 May 2017, 06:53


The file was defaulted to executable
-rwxr-xr-x@ 1 xxxxx staff 33250 9 May 14:08 cross_stitch_tt.py

I might have to go get my shovel!
Thanks for getting back to me.
GIMP Learn rocks...
0

tim
GL Blogger

Post#9 by tim » 09 May 2017, 14:37


have you used .py scripts before this one?
You should try putting in your user's GIMP's plug-ins folder.
aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
0

tim
GL Blogger

Post#10 by tim » 09 Jun 2018, 04:29


A new member (wyh) tried this script and mentioned that it did not work with GIMP 2.10.
So I have just updated 1st post with version 3 of script which works on 2.10.
Thanks wyh! And Welcome to GIMP LEARN forum!
aka Tin
:tree_02:
Tin's: Favorite Index | Simple Art === fb4yt video search | fb4yt recent video views report
Lottery numbers from image | Interested Members in TLF
Paying for hosting is to support my hobby, and donating money made from ads to The Red Cross.
         
0


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
  • Similar Topics
    Replies
    Views
    Last post
• Featuring Members' Works (Image Attachments) •
1: member
2: member
3: member
4: member
5: member

Who is online

Users browsing this forum: No registered users and 14 guests