It is currently 17 May 2021, 16:07

• 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

Making gridded patterns

GIMP or GIMP LEARN forum related Questions
enxio27
Forum Member

Making gridded patterns

Post#1 by enxio27 » 11 Apr 2021, 16:33


Tin, how do you make the grids for your cross-stitch pattern plugins? I would like to do something similar except for Hardanger and Lefkara lace making. There is only one thread color, but the stitch patterns are all different. Here are couple of Web sites to give you an idea of what they look like:

http://www.vettycreations.com.au/hardanger.html

https://threadartproducts.com/lefkara-l ... -identity/

Many (if not all) of the motifs are repeated from one design to another and recombined in different ways, so my idea is to have each motif be a separate image that I can place on a base layer consisting of a grid. My goal is to be able to draw the pattern using GIMP instead of by hand with pencil and graph paper. I'm just trying to figure out how to make the motif images themselves so that they're all on the same scale, but I don't know where to start. Suggestions?
GIMP Learn rocks...

tim
GL Blogger

Post#2 by tim » 11 Apr 2021, 21:19


I am not sure if I understand the stitch patterns are all different part.
If it's one color then there must be places that has that color and places that doesn't have that color...so it's really 2 different colors (one to represent color and one to represent non existence of color or maybe transparent).
If you generate a cross-stitch pattern using 2 colors like black and white and then you'll have the two colors on a generated layer on the cross-stitch pattern image, then you can color select one color and pattern fill it with any pattern (I am guessing you mean motif here).
For the motif (I am thinking like a sample) just have to make a square of motif sample and scale it same size as grid square on generated cs-pattern. Then since you can make selection of a single color, you can copy the scaled to same size motif sample and drag that pattern and drop it onto the selected area and it would fill it all with the motif pattern.
So if your pattern uses 3 different motifs, just generate a cross-stitch pattern using 3 different colors, select each color one by one and drop your desired motifs on them to fill.
If you don't understand what I am talking about in words, I could try to show you with pictures, let me know.
aka Tin

         

tim
GL Blogger

Post#3 by tim » 11 Apr 2021, 21:22


if you draw your pattern using 1 pixel to represent 1 motif square..you can upscale it without interpolation to have for example
20px x 20px squares solid colors, then you can color select and drop/fill any 20x20px motif on it to fill it (or fill on a separate layer so that when you select the next color it doesn't confuse and select part of filled motifs that you've already filled).
let me know if you understand.
aka Tin

         

enxio27
Forum Member

Post#4 by enxio27 » 11 Apr 2021, 22:17


I think I understand, but let me show you an example of what I'm talking about. Here is part of a pattern (it actually extends across to the next page, but I didn't scan that part). Notice that the threads are BETWEEN the grid lines (which represent the threads of the fabric itself). The dots at the ends of some of the threads indicate where the stitch begins after the needle is brought up from the wrong side of the fabric. The various motifs of the design are repeated around the pattern. I would like to be able to create images of each type of stitch group (for instance, the set of five parallel stitches). (There are also dotted lines to indicate lines of symmetry, but I can always add that later.)
Hardanger Pattern.jpg
Hardanger Pattern.jpg # (214.6 KiB) Viewed 1044 times (Thumbnail | Recognize | Sq Tile | LNFI)

And here is what it looks like when actually stitched up:
Hardanger Photo.jpg
Hardanger Photo.jpg # (174.42 KiB) Viewed 1044 times (Thumbnail | Recognize | Sq Tile | LNFI)
GIMP Learn rocks...

tim
GL Blogger

Post#5 by tim » 11 Apr 2021, 22:21


I wasn't sure if you could understand me from words only...so here are steps (I hope I understood you correctly about your grid designing of using repeated motifs).
Here goes:
1. File -> New (for example:set New image as 11px x 11px)
2. Zoom in.
3. View -> Show Grid
4. Image -> Configure Grid, then set Horizontal and Vertical to 1 Pixels (or however you want)
5. See Image below
motif-work-001.jpg
motif-work-001.jpg # (49.66 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
6. Use Pencil tool, set Brush size to 1.00 and draw on image the pattern you want
7. See Image below
motif-work-002.jpg
motif-work-002.jpg # (51.06 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
8. Once you're happy you can hide the grid.
9. Image -> Scale Image and upsize it to size you want per square (for example if I want to have 20px x 20px per square I enter "11*20" into Width [while having aspect ratio locked so I don't have to enter height it'll figure it out automatically]). For Interpolation: select "None". Then click on Scale to scale it to that size without interpolation.
10. See Image below. (The grid was now too distracting so I turned it off by using Step 3).
motif-work-003.jpg
motif-work-003.jpg # (52.58 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
11. Create/Open up a motif (for example I have this 200x200px blue design I just doodled). See image below
motif-work-004.jpg
motif-work-004.jpg # (49.61 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
12. Create/Open up a 2nd motif (for example I have this 300x300px gray design I also doodled). See image below
motif-work-005.jpg
motif-work-005.jpg # (47.95 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
13. Scale down the motif from step 11 to 20x20px (with Interpolation: Cubic). 20x20 as the size we wanted to work with when we upscaled in step 9.
14. Scale down the motif from step 12 to 20x20px as well so it matches our 20x20 desired scale.
15. Go to first blue motif. Ctrl+A, Ctrl+C to copy the whole motif.
16. Go to our pattern image, Select by Color (or Shift+O [That's shift Oh]). Adjust the Threshold to 0.0 so it doesn't select any other color but only exact color we choose.
Click on a black area on our pattern to select that color.
17. Layer -> New (to fill with our first motif).
18. Drag the first square (which is the pattern from clipboard) in Pattern's window and drop it on the image. See below as it would fill our selected area on new layer.
motif-work-006.jpg
motif-work-006.jpg # (52.56 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
19. Now click on bottom layer, the layer that had our black and white pattern.
20. Click on a white area to select white area.
21. Go to 2nd gray motif. Ctrl+A, Ctrl+C to copy the whole motif.
22. Go back to our pattern image, Create new layer and drag (like step 18) first square onto image.
See result below.
motif-work-007.jpg
motif-work-007.jpg # (67.26 KiB) Viewed 1043 times (Thumbnail | Recognize | Sq Tile | LNFI)
aka Tin

         

enxio27
Forum Member

Post#6 by enxio27 » 11 Apr 2021, 22:41


Ok, I understand what you're saying. That will be useful after I get my images made. What I'm having trouble with is creating the images to start with (let's say, one of the groups of 5 stitches, called a "kloster block"):
kloster block.jpg
kloster block.jpg # (5 KiB) Viewed 1042 times (Thumbnail | Recognize | Sq Tile | LNFI)
I could scan some of them from an existing pattern such as this one, but there are some that I've created myself for which there is no printed pattern. I want to be able to "draw" them using GIMP (or maybe InkScape) and have them look as neat and crisp and clear as a printed pattern. I could "draw" them pixel by pixel, but I'm hoping for something faster than that. Once I have the individual images, I can drag them into position over a layer containing a grid.
GIMP Learn rocks...

tim
GL Blogger

Post#7 by tim » 11 Apr 2021, 23:37


if your "kloster block" or whichever pattern is not contained in the exact square (going over gridlines like you say), maybe you'd want to do it like connecting pipes over more than just it's own grid.
like you could do multi-layer...for example for the ones where stitches are going from top to bottom so they go over bottom grid-line,
you could make partial image of thread ends come out starting at the top of grid and go a bit downward but transparent everywhere else.
The before scaling up your pattern, select black and copy move it downward by 1 pixel on a separated layer.
This way when you scale up you can just select that downwarded layer black and fill it with just the ends of thread.
Let me explain with images.
1. Mark the squares that where the grid go over with red (or whatever color you choose just so you can go back and fill it later) on a separate layer (Do this before you upscale so it's easier to work with pixels as individual squares).
motif-over-grid-lines-001.jpg
motif-over-grid-lines-001.jpg # (49.24 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
2. After upscaling, fill black with your motif
motif-over-grid-lines-002.jpg
motif-over-grid-lines-002.jpg # (56.51 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
3. Now select reds and fill with your motif's ends (which is a separate motif with transparency).
motif-over-grid-lines-003.jpg
motif-over-grid-lines-003.jpg # (55.97 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
4. Working with layers allows you turn on/off whatever you like on demand.
motif-over-grid-lines-004.jpg
motif-over-grid-lines-004.jpg # (56.69 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
Here are the motif and motif-ends i used just in case you're wondering.
motif.jpg
motif.jpg # (3.25 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
motif-end.png
motif-end.png # (3.44 KiB) Viewed 1040 times (Thumbnail | Recognize | Sq Tile | LNFI)
The important thing is making each image of yours match another to create illusion of motif going over grid-lines or connected with other threads on the grid. If I were you I'd make a background motif of the little squares, and then the threads would just be theads alone, black and over transparent squares, that way you can turn anything on off or even have threads going overlapping each other. Remember to work with layers ...always...it makes it much easier to remove or add without worrying about mistakes along the way.
aka Tin

         

enxio27
Forum Member

Post#8 by enxio27 » 12 Apr 2021, 01:29


The grid lines don't actually have to be part of the motif. I can overlay the motif on a grid when I combine the motifs into a pattern. I guess, for starters, how do I draw those five lines that make up the kloster block and have them be parallel, straight, equal length, and evenly spaced? And how do I get the dot on the end of each one? That's really the part that has me stuck.
GIMP Learn rocks...

tim
GL Blogger

Post#9 by tim » 12 Apr 2021, 02:17


Use guides.
Image -> Guides -> New Guide. Create multiple guides that are evenly spaced since you can enter exact position (by pixels).
Then once you have all your guides, you can choose View->Snap To Guides (I think it's on by default already).
But after that you can use the brush tool and hover over a guide or where horizontal and vertical guides intersect and your brush should snap to the guide this way you can create paralell by have 5 guides for 5 threads and 2 guides crossing the 5 to cut start and end the threads. and for the dot just choose a bigger round brush and dot it where it snaps to guides.
aka Tin

         

tim
GL Blogger

Post#10 by tim » 12 Apr 2021, 02:22


another way would be to draw one thread and crop it so that when pasted side by side they'll all be the same and use the same technique of dragging and dropping a pattern except instead of squares you're dragging a long vertical rectangle onto an image that is 5 times it's width and the pattern will fill in exact shape for you. ...when drawing if you click on the starting point, then hold shift it'll show you that it'll extend to wherever you drag the mouse too, then if you hold ctrl it'll snap to some increments of angle...
you'll see it when you move the mouse around (while still have shift and ctrl held) now if you get close to straight it'll make it perfectly straight or angled...now click again where you like and it'll draw straight line.
aka Tin

         


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 12 guests