It is currently Sun Jun 21, 2026 10:16 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 20 posts ] 
Author Message
 Post subject: Denim Script
PostPosted: Thu Jan 30, 2014 9:44 am  (#1) 
Offline
Script Coder
User avatar

Joined: Apr 13, 2010
Posts: 244
Image

This script is based on my Denim Tutorial and will create the basic denim background for you. It's up to you to create the seams, folds, stitching. :)

The attached zip file contains the script and pattern which is necessary to create the texture. Once added to GIMP, you can find the script under Filters > Render > Denim... You pick the color, hit OK and the script does the rest.

Enjoy!


Attachments:
denim_gimp_script_by_fencepost.zip [1.99 KiB]
Downloaded 351 times

_________________
I'd rate you as an upper-middle-lower-mod with pro-novice-inter tendencies.....and a twist of lime! Of course, my rating scale is completely objectively subjective, but ALWAYS consistently inconsistent.
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: Denim Script
PostPosted: Thu Jan 30, 2014 11:37 am  (#2) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16038
Fantastic fencepost! Thank you. :)

_________________
Image


Top
 Post subject: Re: Denim Script
PostPosted: Thu Jan 30, 2014 12:18 pm  (#3) 
Offline
Script Coder
User avatar

Joined: Apr 13, 2010
Posts: 244
No problem!

_________________
I'd rate you as an upper-middle-lower-mod with pro-novice-inter tendencies.....and a twist of lime! Of course, my rating scale is completely objectively subjective, but ALWAYS consistently inconsistent.


Top
 Post subject: Re: Denim Script
PostPosted: Thu Jan 30, 2014 4:21 pm  (#4) 
Offline
GimpChat Member
User avatar

Joined: Mar 23, 2012
Posts: 7388
Location: Göteborg at last!
Thanks FP.


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 2:07 pm  (#5) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
I get an error when running this script:
Image


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 2:47 pm  (#6) 
Offline
GimpChat Member
User avatar

Joined: Apr 15, 2017
Posts: 1837
The parameters it uses for bump-map are for older versions of Gimp and out of range for Gimp2.10x bump-map. You just need to edit the parameters to match the current bump-map range in the script. This will present a good opportunity for you to learn how to edit scripts....


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 2:53 pm  (#7) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
racer-x wrote:
The parameters it uses for bump-map are for older versions of Gimp and out of range for Gimp2.10x bump-map. You just need to edit the parameters to match the current bump-map range in the script. This will present a good opportunity for you to learn how to edit scripts....


If I were to edit this script, what line would I change?


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 3:01 pm  (#8) 
Offline
GimpChat Member
User avatar

Joined: Apr 15, 2017
Posts: 1837
I haven't installed this script, but reading it, I would guess you should start editing line 70.


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 3:10 pm  (#9) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
racer-x wrote:
I haven't installed this script, but reading it, I would guess you should start editing line 70.


I'm not a coder and I looked at it. I'm not sure what numbers to change or if I have to change them each time I use the script. So I will leave it up to the coders.


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 3:48 pm  (#10) 
Offline
GimpChat Member
User avatar

Joined: Apr 15, 2017
Posts: 1837
Well I just installed this script out of curiosity, I then edited it successfully by changing one parameter. The error reports water elevation out of range @255. If you run Bump-Map on an image, you will see that Water Elevation runs from 0 - 1.

So what number do you think you need to change in line 70?

(plug-in-bump-map RUN-NONINTERACTIVE image denimLayer patternLayer 135.0 45.0 3 0 0 255 0 TRUE TRUE 2)


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 4:27 pm  (#11) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
racer-x wrote:
Well I just installed this script out of curiosity, I then edited it successfully by changing one parameter. The error reports water elevation out of range @255. If you run Bump-Map on an image, you will see that Water Elevation runs from 0 - 1.

So what number do you think you need to change in line 70?

(plug-in-bump-map RUN-NONINTERACTIVE image denimLayer patternLayer 135.0 45.0 3 0 0 255 0 TRUE TRUE 2)


I'd have to change 255. I will try that. I made the change and it works. :)


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 4:37 pm  (#12) 
Offline
GimpChat Member
User avatar

Joined: Apr 15, 2017
Posts: 1837
Give a man a fish and you feed him for a day.
Teach a man to fish and you feed him for life.


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 4:52 pm  (#13) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
racer-x wrote:
Give a man a fish and you feed him for a day.
Teach a man to fish and you feed him for life.


Agreed! :) I'm just not a coding person but I will try.


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 5:29 pm  (#14) 
Offline
GimpChat Member
User avatar

Joined: Apr 15, 2017
Posts: 1837
I'm not a coder either. Something like this is like through spaghetti against a wall to see if it sticks.........


Top
 Post subject: Re: Denim Script
PostPosted: Fri Dec 13, 2019 10:31 pm  (#15) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
I agree.


Top
 Post subject: Re: Denim Script
PostPosted: Sat Dec 14, 2019 1:14 am  (#16) 
Offline
Administrator
User avatar

Joined: Aug 10, 2012
Posts: 14049
Location: Native to NYC living in Arizona, Gimp 2.8 - 3.0, Win 11 PC.
racer-x wrote:
I'm not a coder either.
Something like this is like through spaghetti against a wall to see if it sticks.........

Love the "spaghetti against a wall" trick.
:hehe

_________________
Image
"A wise man learns more from a foolish question than a fool can learn from a wise answer"
Image


Top
 Post subject: Re: Denim Script
PostPosted: Sat Dec 14, 2019 4:22 am  (#17) 
Offline
GimpChat Member
User avatar

Joined: Jan 20, 2013
Posts: 14831
Location: roma, italy
change the line into:
(plug-in-bump-map RUN-NONINTERACTIVE image denimLayer patternLayer 135.0 45.0 3 0 0 1.0 0 TRUE TRUE 2) ;;;255>1.0

_________________
"Where am I ?"


Top
 Post subject: Re: Denim Script
PostPosted: Sat Dec 14, 2019 6:39 am  (#18) 
Offline
GimpChat Member
User avatar

Joined: Jan 20, 2013
Posts: 14831
Location: roma, italy
@Mackenzieh
If you prefer, this is the script converted into python
Attachment:
fp_denim_script_py.7z [1.03 KiB]
Downloaded 161 times

_________________
"Where am I ?"


Top
 Post subject: Re: Denim Script
PostPosted: Sat Dec 14, 2019 8:45 am  (#19) 
Offline
GimpChat Member
User avatar

Joined: Jan 20, 2013
Posts: 14831
Location: roma, italy
Remember the script requires
Attachment:
diagscanline3.pat [138 Bytes]
Downloaded 129 times

_________________
"Where am I ?"


Top
 Post subject: Re: Denim Script
PostPosted: Sat Dec 14, 2019 5:59 pm  (#20) 
Offline
GimpChat Member
User avatar

Joined: Jul 06, 2013
Posts: 2661
Location: California
Thanks for the python version. I have the scheme version working. :)


Top
Post new topic Reply to topic  [ 20 posts ] 

All times are UTC - 5 hours [ DST ]



* Login  



Powered by phpBB3 © phpBB Group