It is currently Tue Jun 09, 2026 11:30 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 47 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Wed Feb 23, 2011 9:03 pm  (#21) 
Offline
Script Coder
User avatar

Joined: Apr 23, 2010
Posts: 1553
Location: not from Guildford after all
PhotoComix wrote:
my point was that the sg script you call does something very different if there is a selection or not

...basically i was suggesting only to try the saulgoode script with and without selection just to check its peculiarity

You are correct about the behavior being somewhat peculiar. My logic was that if nothing were selected then the expected behavior would probably be to not scale the layer contents -- it is "protected" by virtue of not being outside the (non-existent) selection -- but to resize the layer to the image size, filling the added space with transparency. But this would be identical to performing "Layer->Layer to Image Size" and so I figured it would be more useful to scale the entire layer (which is sometimes handy).

_________________
Any sufficiently primitive technology is indistinguishable from a rock.


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Wed Feb 23, 2011 10:06 pm  (#22) 
Offline
GimpChat Member
User avatar

Joined: Oct 06, 2010
Posts: 4050
Saulgoode: that seems to work, so the clincher was getting the active layer first. I still don't understand how just simply using the toggles caused the first variation to "break".

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Wed Feb 23, 2011 11:44 pm  (#23) 
Offline
Script Coder
User avatar

Joined: Apr 23, 2010
Posts: 1553
Location: not from Guildford after all
mahvin wrote:
Saulgoode: that seems to work, so the clincher was getting the active layer first. I still don't understand how just simply using the toggles caused the first variation to "break".

No offense intended toward Micomicom -- I believe this charcoal script was his first ever -- but there is some margin for improvement in his technique ( :) ) and, combined with the code which you added, I got lost in keeping track of what layer was what in his code. Furthermore, there is a peculiarity in my Extend Layer script (which I should probably re-think) and all of this amalgamated into a cascading succession of failures which, ironically, led to your script actually working (can you tell I used to be a rocket scientist).

Technical explanation (about 20 times more complicated than if we all did things right):

At the point in the script where you wish to scale the layer to the image size, the variable 'drawable' is set to micromicom's original 'charcoal-layer'. However, the active layer will be either 'charcoal-layer' (if no new layer was created) or 'layer-charcoal' (the new layer your added code introduced).

The reason my Extend Layer script functioned properly with your call is because it actually ignores the second parameter passed to it and instead retrieves the image's active layer. Thus the Extend Layer script worked when you passed 'drawable' (i.e., 'charcoal-layer') to it because it was operating on the active layer ('layer-charcoal', your newly created layer). If my script actually honored the second argument, your call would not have worked because 'drawable' was not set to the new layer ('layer-charcoal') but to the original 'charcoal-layer'.

As to why my script ignores the second parameter, my reasoning was that if a layermask were active when the script was called, the second parameter would be the ID of that mask; but in such a situation I would want my script to extend/scale the layer corresponding to the mask, not the mask itself. I thought I would be cute and use 'gimp-image-get-active-layer' to retrieve this layer (if a mask is the active drawable, its associated layer is the active layer). This works great if the script is invoked from the menus, but I did not really consider the case of my script being called from another script (who would ever do such a thing?!) -- though I should have.

_________________
Any sufficiently primitive technology is indistinguishable from a rock.


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Thu Feb 24, 2011 2:18 am  (#24) 
Offline
GimpChat Member
User avatar

Joined: Oct 06, 2010
Posts: 4050
All I added was a layer (layer-charcoal) and a buffer, in order for my new layer to successfully launch. And additionally, your script for maximizing the original layer, should the resize for optimum effect be utilized. The structure or sequence seemed right, but your explanation makes me seriously reconsider calling another script, even though I lucked out.

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Feb 26, 2011 10:27 am  (#25) 
Offline
Retired Staff
User avatar

Joined: May 22, 2008
Posts: 6946
Location: Somewhere in GIMP
Original image here.

I love this effect. I put the charcoal layer above the image layer and set the layer mode to Value. I guess you could say that the leopard is in the pink. :hehe

Image

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


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Feb 26, 2011 9:25 pm  (#26) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16023
Are you going to add layer modes to the script? That would be sweet. :)
One of the things i requested was soft light mode to keep the color.

_________________
Image


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Feb 26, 2011 9:39 pm  (#27) 
Offline
GimpChat Member
User avatar

Joined: Oct 06, 2010
Posts: 4050
I'm a total noob on scripting, Rod. I'm looking at other scripts that do similar things I like, and trying to figure out how to add them to this script without messing it up.

In an ironic way, I'd like a script that basically asks me, what would you like to do to this image, with a slew of options to toggle off and on, and then run the gauntlet of insanity and see what happens, hahaha... <pinches self> In case I am dreaming...

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sun Feb 27, 2011 3:55 am  (#28) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16023
I have one of those its called imagination i think :lol
Well either way, nice job on the script and god luck with any more you decide to play around with. :)

_________________
Image


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Tue Mar 01, 2011 2:34 pm  (#29) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
Have a look to http://www.flickr.com/groups/gmic/discu ... 175779086/

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Tue Mar 01, 2011 2:47 pm  (#30) 
Offline
GimpChat Member
User avatar

Joined: Oct 06, 2010
Posts: 4050
It would be cool if someone stepped up and implemented it in G'MIC. Have you tried to perform the tasks manually, PC?

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Tue Mar 01, 2011 3:05 pm  (#31) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
yes...everything woked fine almost till the end ... then we had a electric breakdown because my father turned on simultaneusly a electric heater, a grill and a old washing machine :hoh :gaah

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Fri Mar 18, 2011 2:26 am  (#32) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
Charcoal is now also a gmic filter (thank David!!) ,and as gmic filter offer a preview (zoomable and pannable) and more flexible options for input/output

Not sure if result are fully equivalent but should be very similar..but add your feedback

for more info see http://www.flickr.com/groups/gmic/discu ... 175779086/

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Fri Mar 18, 2011 3:24 am  (#33) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16023
Thanks PC very nice - though it took me a while to find B&W - charcoal in the menus, basically because for some stupid reason i was looking for chalk - go figure. :P :lol
Nice results i like this effect.

Image

_________________
Image


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Fri Mar 18, 2011 2:32 pm  (#34) 
Offline
GimpChat Member
User avatar

Joined: Mar 02, 2011
Posts: 1850
Location: Michigan
How do we get this G'MIC filter?

Do I download the ZIP?

_________________
Image
I'm back I think


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Fri Mar 18, 2011 7:26 pm  (#35) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16023
No the filter is installed with GMIC under "Artistic"
B&W - Charcoal

_________________
Image


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Fri Mar 18, 2011 7:28 pm  (#36) 
Offline
GimpChat Member
User avatar

Joined: Mar 02, 2011
Posts: 1850
Location: Michigan
Part of the new update which doesn't work for me :( nothing is working for me right now

_________________
Image
I'm back I think


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Mar 19, 2011 4:02 am  (#37) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
check for older gmic files hidden somewhere delete them all and get the last version

i just had the same problem, solved as i just explained

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Mar 19, 2011 5:54 am  (#38) 
Offline
GimpChat Member

Joined: Apr 12, 2010
Posts: 5870
apparently the final result is always 4 times bigger then original (meaning each side is doubled) and the invert FG/BG box has no effect

A windows 7 only issue? I had still to install last gmic in my other OS (take a bit since only 7 is connected to the net ) could you check in linux ?

this my attempt http://www.box.net/shared/857rutdsbr as you may seen is always 4x bigger and always look as a negative so obviously the invert FG/BG doesn't work at least in my PC

_________________
My 3D Gallery on Deviantart http://photocomix2.deviantart.com/
Main gallery http://www.flickriver.com/photos/photocomix-mandala/
Mandala and simmetry http://www.flickriver.com/photos/photocomix_mandala/

Image

Mrs Wilbress


Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Mar 19, 2011 11:34 am  (#39) 
Offline
GimpChat Member
User avatar

Joined: Mar 02, 2011
Posts: 1850
Location: Michigan
Slinky and Charcoal Fun :D


Attachments:
SlinkyCharcoaled.png
SlinkyCharcoaled.png [ 37.74 KiB | Viewed 2165 times ]

_________________
Image
I'm back I think
Top
 Post subject: Re: Charcoal Script Reworked - UPDATED
PostPosted: Sat Mar 19, 2011 2:45 pm  (#40) 
Offline
Global Moderator
User avatar

Joined: May 16, 2010
Posts: 16023
Go Willy! :)

_________________
Image


Top
Post new topic Reply to topic  [ 47 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC - 5 hours [ DST ]



* Login  



Powered by phpBB3 © phpBB Group