It is currently Wed Apr 24, 2024 8:15 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 2:06 pm  (#1) 
Offline
GimpChat Member

Joined: Mar 29, 2011
Posts: 346
Location: Wisconsin
Here is a Pin-Stripe border script (Oregonian's tutorial)
http://gimpchat.com/viewtopic.php?p=27283#p27283

It works on the current layer so it is a little more versatile. The width and colors can be specified. Tested on RGB and gray-scale images.

Appears at Filters > Decor > Pin-Stripe Border...

Edit1: Updated the script to fix frame shift problem.
Edit2: Set paint tool and add option to merge border down or not.


Attachments:
Pin-Stripe Border.scm [3.53 KiB]
Downloaded 370 times

_________________
Image


Last edited by bkh1914 on Tue Jul 05, 2011 8:05 pm, edited 2 times in total.
Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 2:31 pm  (#2) 
Offline
GimpChat Member

Joined: Mar 29, 2011
Posts: 346
Location: Wisconsin
Drat!!!
I just noticed that the border is lopsided by one pixel because of the way GIMP strokes a selection from a script.

I'll have it updated in a few minutes... I hope.

Fixed!!!
Updated the script in the original post.

_________________
Image


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 3:21 pm  (#3) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
Slick! :bigthup Thank you!

A suggestion. If you'd preface your filenames with bkh, we'd know who did them in the file list.
bkh-pin-stripe-border.scm

Done with the default settings.
Image

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 4:36 pm  (#4) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
Would it be possible to make a choice in the script dialog to leave the border on a separate layer for later editing if desired?

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 4:44 pm  (#5) 
Offline
Script Coder
User avatar

Joined: Apr 23, 2010
Posts: 1553
Location: not from Guildford after all
bkh, nice job on the pin-stripe script. I'd suggest, however, that you use 'gimp-context-set-paint-method' so that your script is ensured to paint with the pencil or paintbrush, regardless the active paint tool. As currently written, depending upon what paint tool is active when the script is executed, the result might not be as expected.

Since the PDB browser does not list the available methods, I will post them here: "gimp-pencil", "gimp-paintbrush", "gimp-eraser", "gimp-airbrush", "gimp-ink", "gimp-clone", "gimp-heal", "gimp-perspective-clone", "gimp-convolve", "gimp-smudge", and "gimp-dodge-burn". The values are indeed strings, so the quotation marks should be included in the procedure call. For example,
(gimp-context-set-paint-method "gimp-paintbrush")

_________________
Any sufficiently primitive technology is indistinguishable from a rock.


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 5:04 pm  (#6) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
saulgoode wrote:
bkh, nice job on the pin-stripe script. I'd suggest, however, that you use 'gimp-context-set-paint-method' so that your script is ensured to paint with the pencil or paintbrush, regardless the active paint tool.
The pencil would be the best one. No antialiasing. Everything is horizontal or vertical so it's not needed.

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 5:37 pm  (#7) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
Nice script!
Thanks for sharing it bkh. :)

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 8:02 pm  (#8) 
Offline
GimpChat Member

Joined: Mar 29, 2011
Posts: 346
Location: Wisconsin
saulgoode, thanks for the compliment and information.
As you probably noticed, I had already run into trouble with the paint mode and opacity. I was wondering what the paint method did. I've added it to the script.

Oregonian wrote:
Would it be possible to make a choice in the script dialog to leave the border on a separate layer for later editing if desired?

Done.

Oregonian wrote:
The pencil would be the best one. No antialiasing. Everything is horizontal or vertical so it's not needed.

Looking at your tutorial, the final stroke is 5px, which gives a 2.5px wide line inside the frame. That feathers the outer line into the inner line, which gives a quasi bevel effect. The paint brush will do the same feathering, the pencil won't. The script uses a 100% hard brush so it produces exactly the same type of stroke as the line stroke does. I'll leave it that way for now.

Thanks for the feedback everyone.

Modified script is in the original post.

_________________
Image


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 8:16 pm  (#9) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
Nicely done! :)

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Pin-Stripe Border Script
PostPosted: Tue Jul 05, 2011 8:24 pm  (#10) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6947
Location: Somewhere in GIMP
Very well done, bkh!!

_________________
Image
World War IV will be fought with sticks and stones. - Albert Einstein


Top
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Attachment(s) How can I create this border?

4

No new posts Attachment(s) Border around GIMP menus

5

No new posts Attachment(s) Tin's Gradient Border Select

4

No new posts Attachment(s) Beautify Texture & Border Ver.2

3

No new posts Attachment(s) How to add a border caption on Image for print?

5



* Login  



Powered by phpBB3 © phpBB Group