PDA

View Full Version : New plugin : Crop Tool - Updated


marcus_civis
05-12-06, 03:56 AM
CT_thumb.jpg
grab.jpg

Crop Tool provides an easy way to crop or resize the canvas without scaling.

*Click and drag the mouse to define the crop area
*Reduce or enlarge the canvas
*Nudge crop area for accurate cropping

Tip: Cropping a document cannot be undone. In order to be able to undo, save the document first, you can then press the Document:Revert button to undo the crop if you wish.

This ZBrush plugin builds on the CropBox routine by Svengali,
the code for which he posted in this thread (http://www.zbrushcentral.com/zbc/showthread.php?t=22826) in June 2005.
I probably wouldn't have written this without that code, so many thanks Sven.
For anyone that's interested, my code is posted in the same thread.

INSTALLATION
Unzip the zip file to your ZStartup\ZPlugs folder ..\ZBrush2\ZStartUp\ZPlugs).
You may need to create the ZPlugs folder if you have a new installation of ZBrush.
Restart ZBrush. You should now have an Crop Tool subpalette in the Document palette, with a Select and Crop button.

***Updated May 22 2006***
I've added a small enhancement which makes this a little more useful. There is now a 'Snap' option which will snap the cursor to the canvas when it is closer than 5 pixels. You can turn the option on and off.

Full instructions in the zip.

I hope you fine Crop Tool useful,

Edit: 23 May 2006 : After a suggestion by the inestimable Boozy Floozie, here is a
MRGBZGrabber version. (http://www.zbrushcentral.com/zbc/showpost.php?p=278516&postcount=25)

cameyo
05-12-06, 04:09 AM
WOW !!!:tu::tu::tu:
Thanks...

cameyo

sirquadalot
05-12-06, 04:21 AM
THANKS!!! D/L now:cool:

Bas Mazur
05-12-06, 04:42 AM
Wow, just waiting for this!!Thanks :tu: :tu:

Works fine on my Mac! 5*

Frenchy Pilou
05-12-06, 04:50 AM
...will be a "magic wand" to select (& invers possible) something 2D on the canvas follow a number of colors for a copy / Cut / Past?
Have happy scripting! :cool:

Sebcesoir
05-12-06, 05:11 AM
Ah thats a good idea... Now you have a precise control of the croped areas..


Nice! thanks marcus!

Svengali
05-12-06, 05:32 AM
Excellent work Marcus. I especially like the dynamic crop box display. I think your earlier version didn't have the tweaking controls. They ice the cake.

Another useful script, very well done.

Sven

PS. Thanks for posting the subroutine, too. I already have several scripts that will benefit greatly from your enhancement!

saltapiedras
05-12-06, 06:30 AM
Gracias. Eres genial, Marcus. :tu: :tu: :tu:

Buckie
05-12-06, 06:51 AM
Damn fine little script there MC...:cool:

lemonnado
05-12-06, 09:18 AM
I tell ya... that darn virus....
:tu: :tu: :tu:
Lemo

Atwooki
05-12-06, 10:39 AM
Really handy Tool Marcus - Thanks for sharing (and to Svengali of course also!) :tu: :)

Chris

marcus_civis
05-12-06, 02:24 PM
Thanks for the comment guys, much appreciated. :)

Frenchy: a nice idea but I think very difficult (if not impossible) to zscript... :(

Cheers,

Frenchy Pilou
05-12-06, 03:03 PM
...new commands will be add with the new version ;)

bicc39
05-13-06, 03:54 AM
Many thanks!!!
Just curious, is there anyway you can have zbrush
make coffee, play dvd's, dust floors.
You have covered almost everything else:tu: :tu:

wenna
05-13-06, 04:58 AM
Thanks so much for the new script!! Another great one!!


wenna

Anatom
05-13-06, 12:29 PM
:D

marcus_civis (http://www.zbrushcentral.com/zbc/member.php?u=20323) vbmenu_register("postmenu_276482", true); ,
thanks so much dear friend.
This is one of the most desired plugin, for previously I have been using other software to crop the needed piece of the picture after saving the default Zbrush document.
Also it's great that the interface could be saved with the button Crop placed at the side of the Canvas.
Seems like next step may be your broadening the plugin by capacity to store the cropped parts nearby the main canvas so that to combine different crops.
Or else...!!!!!!!!!!!!
:lol:

Anatom

andreseloy
05-15-06, 02:05 AM
Marcus+Sven explosive combination:D :tu:
Thanks to both!
Andreseloy

froyd
05-15-06, 06:50 AM
Ooooohh thank you very much! I´m very happy about that script.

cheers!
froyd

marcus_civis
05-22-06, 04:31 AM
Thanks for the comments, guys. :)

I've just updated the plugin to include a 'Snap' feature for easier cropping to existing canvas edges. Used in conjunction with the 'expand by 1 pixel' feature this makes a quick way to add a border to the canvas. (Change background color to suit.)

Cheers,

boozy floozie
05-22-06, 06:04 AM
This looks fantastic you ol' devil - you dun it again!!!!!

:tu: :tu: :tu:


If you could also write a script so I can drag the MRGBZGrabber where ever I want before releasing it I'd be your cell bitch for the duration of my stay upon this crusty earth.

What d'ya say.... is it doable?


......Nobody tries to be lah-di-dah or uppity--There a cup-o'-tea for all.

Wordsmith
05-22-06, 07:23 AM
Once again.....a hearty thanks. You really do so very much for this forum.

Thank you.

Word.

ryankingslien
05-22-06, 10:58 AM
Marcus -
You are again my hero! Very cool! :)

Ryan

50'sKID
05-22-06, 11:42 PM
Just wondering,...is it possible to resize a document in one direction only like a graphics program? 50.

Frenchy Pilou
05-23-06, 12:25 AM
If you could also write a script so I can drag the MRGBZGrabber where ever I want before releasing it I'd be your cell bitch for the duration of my stay upon this crusty earth.
Why not use the "tilde" (or similar following the country keyboard)
for move the entiere canvas and center that you want in the "midle" of the screen and then use the MRGBZgrabber more confortable :rolleyes:
Astounding isn't it? :D

Ps Your texts are always sugar schamallows to read :lol:
even if I understand the half part :lol:

marcus_civis
05-23-06, 05:22 AM
Thanks for the comments, guys. :)

50,
If you mean stretch or compress the canvas by changing the document proportions then you can do that using the regular Document:Resize button. Switch off the Pro button first, enter the new width or height in the sliders then press Resize. This can produce interesting results if you use markers! ;)

If you could also write a script so I can drag the MRGBZGrabber where ever I want before releasing it I'd be your cell bitch for the duration of my stay upon this crusty earth.

What d'ya say.... is it doable?

Boozy, nothing is impossible for the stubborn. :)

Here is a version for the MRGBZGrabber. It adds a 'Grab Select' button to the Tool palette. Click and drag to select an area. After that, press the 'Move' button to move around the box with the mouse, as well as nudge or increase the size by 1 pixel increments as for the crop Tool.

Full instructions in the zip.

P.S. I'm afraid to ask but... what's a 'cell bitch'?

Cheers,

slocik
05-23-06, 05:25 AM
cool, we love you, i would test it, if only my head wouldnt hurt so much for some unknown reason :/

wenna
05-23-06, 11:42 AM
Just have to say Thank-you again!! This are fantastic!! Makes things a bit easier for me! ThankyouThankyou and a ton of Thank you's!!!


wenna

50'sKID
05-23-06, 12:35 PM
Hi Marcus, what I meant was, say you need some extra room on the right side of a picture, can you add pixols and expand just that side? That could come in handy. :) 50.

marcus_civis
05-23-06, 01:50 PM
50,
Yes, you can do that easily. Just drag the crop box out to one side. With snapping on, the box will snap to the other three edges if you drag the mouse close by.

boozy floozie
05-25-06, 07:48 AM
Crikey I missed your reply - fantastic!!

Many thanks indeed.

boozy floozie
05-25-06, 08:10 AM
It works wonderfully.

I never realised that scripts could also be added like this for tool options.

I was a bit dumb at first and went looking for it in my excitement in the plugins drop down untill I calmed down a read through what you actually said. :o

marcus_civis
05-25-06, 08:27 AM
Great, I hope you find it useful. It's not pixel-accurate in that sometimes the dimensions of the grab vary slightly from the ones indicated but I don't suppose that matters too much.

wenna & slocik,
Many thanks for your comments. :)

50'sKID
05-25-06, 12:39 PM
Hey, marcus, thanks much for that expansion info! I have needed that before. Fantastic! 50.

aminuts
05-27-06, 10:38 PM
Hot Damn!

for me a double header of excellence!! my 2 fav scripters posting while I've been away......it's like xmas around here.

Marcus......Cellbitch=wife in prison but in zbrush land it means woozy has to send you one print(could be postcard size) a year for life.....of course autographed and all! :D

but I digress......sigh you and Sven remind me that I once again need to update my links page. like yesterday!

Thanks again for another super duper script.

I thoroughly appreciate the time put into them all and if I ever win the lottery.....you and sven and digits and cameyo and anyone I am forgetting here....will definitely get a piece of it!

CG.stalker
05-30-06, 11:41 AM
Nice tool!

wckedsunny
08-23-06, 02:59 PM
Marcus I am having problem cropping my illustrations.

I mean I mostly use double size of canvas and then press half buton, How does the crop tool react when cropping - full canvas and half canvas ?

In which should I be cropping it ? I am confused about the dimensions part.

I cropped one and I got a smaller image then the prefixed frame..

marcus_civis
08-24-06, 03:06 AM
Wicked,
It should make no difference whether you crop at full size or AA Half-size but after cropping your canvas will be returned to full size display. Note that AA Half-size is only an anti-aliased display, your actual canvas size is not changed (though exporting while at AA Half-size will export the anti-aliased half-sized image).

I can't think why you should have ended up with a smaller image than the crop boundary. The code doesn't allow for such a thing to occur. Is it possible that you had zoomed in so that your canvas was larger than actual size? That would account for the effect. The pixel dimensions are the best indicator of what you will get (although under some circumstances, such as zooming right in, there could be a 1 or 2 pixel error).

Cheers,

wckedsunny
08-24-06, 09:32 AM
Marcus I remmember to zoom out as boundries of canvas were not visible eevn at aahalf size.

That might have caused the problem - I will use the tool again today for other illustration, if I have probs i will get back to you.

Regards

wckedsunny
08-25-06, 11:59 AM
Marcus

I realized my mistake.

The photoshop frame dimension should be taken double, so that when i crop that size in zbrush, and aahalfed and rendered it gives me the actual frame size.

I was using normal size when cropping so obviosuly when I aahalf it, it will become even smaller. :o :o

Thanks

marcus_civis
08-25-06, 02:22 PM
Wicked,
Glad you got it sorted. :)

Thanks,

wckedsunny
08-25-06, 02:38 PM
Marcus I have two suggestions for you to make this crop tool sleeker and better.

1) After we create the crop box - if we can input the dimensions directly that will be really better instead of using the arrows.. ;)

2) If after the box is visible we can just select the box and move the whole crop selction with it , placing it anywhere we want ? :D

I think it might be diffcult thats why you never made it that way at the first place.

But you can do something to the arrow buttons to make the crop faster, because everytime its not possible to cancel and crop again because of need of its exact placement and dimension.

When we click on arrow buttons to increase both placement and dimensions- we have to repeatedly keep clicking the mouse button, this way it takes lot of time, if differnce is 100 - 500 pixels specialy for large illustrations like of 4096 x 4096 where u cannot accurately snap the box with mouse..

If you can script it in a way that if we click once and do not leave the mouse button it keeps adding or subtracting without need of clicking again like in many softwares.But when we leave mouse button - it stops. Also if we press and leave it still should behave the same way its behaving now.

Scipting - if mouse button is down it keeps adding/subtracting( both dimensions as well as placement)- i think this programming isnt tough ?

That way even if you are not able to create something for the 2 suggestions above- the problem of cropping it fast will be solved without taking lot of time( for us) and programming ( for you)

let me know what you think. :D

marcus_civis
08-25-06, 02:49 PM
Wicked,

There are limits to what can be done with zscripting - I'm using a zscript Note here creatively to start with - but some of what you suggest may be possible, and I'll bear it in mind for when I get around to an update.

Cheers,

wckedsunny
08-25-06, 03:11 PM
Yes marcus

I realize zscipting isnt that easy to use or even to learn- I am still not getting hold of it. :rolleyes: :D ;)

But zbrush itself is so unique that I think zscripting can be used to create lots and lots of amazing plugins for zbrush in future versions.

These ideas pumps me up, to learn zscripting when ever I give up on it.

We need more creative people here , like you marcus , I might soon join this bandwagon too. :)

Keep creating more plugins :tu: :tu: :tu: , hope you get around the update of crop tool soon.

marcus_civis
08-26-06, 01:52 PM
Thanks Wicked, and have a go at zscripting yourself if it interests you. We could do with a few more zscripters around here. :)
Cheers,

seeker
08-28-06, 11:41 AM
:lol: Thanks a lot for the croptool

tdrs
10-05-07, 12:23 AM
Hi,marcus_civis,
I like these plugins.:lol:
Can you Update 'CropTool 'and 'MRGBZSelect' Plugin? I find that There is a problem.


problem.jpg
ZBrush2

In ZBrush3, It has not show the crop line .

marcus_civis
10-05-07, 12:40 AM
Hi tdrs,

I'm afraid that at the moment an update to these two plugins is impossible due to restrictions in ZBrush 3 zscripting. :cry:

tdrs
10-05-07, 02:40 AM
Thanks for your reply:tu:
It is sorriness.:cry: