PDA

View Full Version : PolyPainting Plugin – custom button set for ZB3



Svengali
08-06-07, 10:25 AM
PolyPainting splash.jpg

What is the PolyPainting custom Button Set?

In ZBrush3 you can no longer paint directly onto texture maps (unless you use Projection master).

Instead, you must paint directly onto the polymesh. The more subdivided the polymesh is, the better resolution and detail in your painting. At some point you will want to transfer your polypainting to a texture map to be exported along with your model (an .obj file.) This PolyPainting button set is designed to simplify and streamline this whole process.

Generally, the button workflow is this:

Assume you have loaded a model with GUV mapping (or imported a pre-UV-wrapped .obj file) and you want to paint on your model. It should be in edit mode. You may also have imported a texture map which should be selected. If not, you can create one and make sure that is selected. The New Map button lets you quickly create one if you need to offering three different sizes.

The Five buttons are used in this order:

1. New Map = If your model doesn't already have one create a texture map and assign it to your model.

2. SaveUV = This critical step creates a temporary .obj file at lowest subD level which preserves your UV mapping, then creates a Morph Target also at lowest subD level and identifies the texture map with the model. You will always be asked if you want the existing texture map colors to be copied over to initialize the PolyMesh - if so press yes. Also, remember you should already have subdivided to the highest possible polymesh resolution BEFORE you agree to copy your texture map to the polymesh - this lets you start with a polymesh version that's as sharp as your original imported texture map!

3. HideMap = Press this button to start or to continue with the polypaint process. The Texture Map is deselected revealing the polygons. It also selects the highest subD level, selects colorize and disables UVs. At this point you may choose to subdivide your model several more times to enhance the polymesh detail. Now you begin polypainting on the model in Draw>Rgb mode using different alpha brushes and optionally, painting with other textures. Avoid modifying your model's surface (Draw>ZAdd should remain off.) When finished painting, move on to step 4.

4. ShowMap = This reselects and displays your map, then changes your model to its lowest subD level. The original UVs are recovered from the stored.obj file and re-applied to your model which is then again set to the highest subD level. With the texture map reloaded it may look like your polypainting is gone... but it's all still there, underneath.

5. PolyPaint to TexMap = Reselects DRAW:Rgb and sets Rgb Intensity to 100%, and transfers the polypainting from your polymesh up onto your texture map.

At this point you simply repeat steps 3, 4, 5 - painting and enhancing your RGB polypainted model, reloading your texture map, then updating it as often as you want.

Used together this button set will hide from view all the repetitive pressing of buttons and settings of slider values so you can focus on poly-painting your model and transferring it to the texture map for eventual export.

Installing the PolyPainting Plugin

Unzip the PolyPainting.zsc file into your ZStartup\ZPlugs folder. The next time you start up ZBrush3 you will find a new subgroup titled PolyPainting, in the TEXTURE Menu which contains the buttons as shown above. The question mark is a help button which pops up the same info outlined above.

The PolyPainting Button Set is free for distribution to the ZBrush community. Please post any bug reports or helpful suggestions to the ZBCentral Forum.

Thanks! - Svengali, August 2007

[Updated August 14th - to include option under the saveUV button that copies the map colors to the polymesh, as suggested by EddyLoonstijn :) )

Doqpelgänger
08-06-07, 10:35 AM
this is great!!! :tu: thanks

SolidSnakexxx
08-06-07, 10:42 AM
Much appriciated! It's going to be a very cool and handy tool ! But can't find the download for it just yet.

marcus_civis
08-06-07, 10:49 AM
Apologies, (wearing my moderator's hat) I had to temporarily remove the file. It will be back up very soon.

EDIT: Back up there, sorry for the delay.

Atwooki
08-06-07, 10:50 AM
Looks like this'll be a GREAT plugin Sven :)

Look forward to this one :tu:

Chris

yvan_c
08-06-07, 10:55 AM
Hi Marcus,


Thanks in advance man. I am new to ZB and need all the help I can get :-)

Cheers,

yvan_c

yvan_c
08-06-07, 10:58 AM
Sorry about my previous post. I meant to say was "Thank you Sven".

Regards,
yvan_c

WailingMonkey
08-06-07, 11:04 AM
This looks awesome, Svengali!

I'm hoping this 'temp .obj' file process will correct the corrupting of UVs I
seem to be continually getting once I re-import my low-poly .obj back into
XSI. Great work, and thank you! :)


WailingMonkey

Svengali
08-06-07, 11:20 AM
Marcus, thanks very much for your help reposting the script. (it does get complicated, doesn't it? :) ).

To everyone else who might download: This first release of the PolyPainting button set is subject to updating, depending on the feedback I get. In my own tests it seems to work fine, however I know there are some situations I couldn't test (particularly exporting the model with the newly created texture map.)

Test it carefully and let me know of any problems. Thanks, Sven

Buckie
08-06-07, 11:35 AM
Another genius but simple plugin... :D

Thank you Sven... :tu:

Plakkie
08-06-07, 12:18 PM
You Plugin Masters are making our lives easier with every addition. Thanks Svengali, this will come in handy! :tu: :tu: :tu:

ancomic
08-06-07, 12:49 PM
Thank you! Nice Plugin

UV coordinated Multi Model...
1. Texeture:UV Check
2. Polypainting:SaveUV
Testing OK!!!:)

Roland Kaiser
08-06-07, 02:04 PM
Cool Plugin, Svengali

Thanks for your hard work and for sharing.

Greets

Roland

andreseloy
08-06-07, 03:35 PM
Thanks Sven

Andreseloy

Erklaerbar
08-06-07, 04:39 PM
hi Sven, thanks a lot. Will use it, have tested it and its a nice workflow improvement.:tu:

Atwooki
08-06-07, 08:53 PM
Seconded from Erklaerbar

Definitey saves a little bit of the ol' grey matter upstairs ;)

Nicely implemented proc. Sven - many thanks :tu: :tu: :tu:

Chris

aminuts
08-07-07, 12:27 AM
Cool! Can't wait to check this one out. Still trying to get everything sorted out from a crash and burn...so far z3 doesn't llike this computer :cry: but have a few days off so hope to get it all sorted out.
Thanks for another cool plugin Sven!

Hey Marcus....looks like I missed something....congrats on the moderator thing!

RAMWolff
08-07-07, 02:45 PM
Thanks for the nifty plugin!! :)

g.g.
08-08-07, 07:24 AM
thanks for another great plugin Sven! :tu: It's been working really well so far, but I had a question: how would you expect the plugin to work polypainting a model with several subtools and through several sessions of opening & closing the Zbrush app? Since the plugin saves off an obj for the morph target I was wondering how it tracks all the related files if I close Zbrush to go home at the end of the day (or if Z crashes).

thanks again for all your hard work.

best,

Gray

Svengali
08-08-07, 10:04 AM
Hi Gray,

I didn't test too much with multiple subtools. What I did first was polypaint all the subtools the way I wanted each of them to be.

Then for each subtool in turn, I selected the subtool, apply GUVmapping, and loaded a new texture map. Then I stepped through the four buttons: saveUV, hidemap, showmap and polypaint to texmap (with no additional polypainting).

Since the selected texture map is simultaneously displayed on all the subtools it can get confusing - it's probably better if you have only the current subtool visible during the process.

In the end you've made a separate map for each subtool. That's as far as I took the tests.

As for interrupted sessions, continuing later should not matter as long as you always start the next subtool by assigning it new UVs, and a new map, then always press the saveUV button first.

I suggest that you experiment... and please post anything you might learn that would be helpful to other users.

Thanks to you and to everyone else for your generous comments!

Sven

g.g.
08-09-07, 06:35 AM
sounds like what I would need it to do. :) thanks again for the helpful tools!

Gray

kokkok
08-13-07, 07:59 AM
thanks so much.

EddyLoonstijn
08-14-07, 02:47 AM
Hi Svengali,
First, I love your plugin. It works beautifully.

Secondly, I would like to add something to your directions for use:
In case of first importing an existing texture for the to be repainted mesh the user should:
1. Select the imported texture in the Texture menu
2. Go in Tools>Geometry to the desired SDIV of the mesh
3. IN Tools>Texture>Hit:Texture to Color
And only then you are ready to Hit: the second button of the plugin: SaveUV, etc.

Thirtly, I have a question: Why did you make the step ShowMap explicit, while I do not see how it helps me to know that this is happening. Your goal with this plugin is - as I understand - to overrule unneccesary hitting of buttons if that canbe done in the unknown background.
So, is it not quicker just to move on in one step from HideMap-and-start-Polypainting to PolyPaint-to-TexMap.
Or maybe, even more simple: In stead of HideMap make a buton: StartPolypainting and then, if you'r finished painting: PolyPaint-To-TexMap.

EddyL

Svengali
08-14-07, 06:26 AM
EddyLoonstijn,

Thanks very much for the constructive feedback!

You are absolutely right about the imported texture map. It needs to be moved onto the polymesh with a Tex>Clr command BEFORE pressing the copyUV button. I had forgotten that.

[Edit: I have modified the plugin's SaveUV button to incorporate your suggestion.]

As for having the ShowMap step? To avoid confusion, I wanted the user to EXPLICITLY click and see the texture being updated. I originally had this happen in one step as you suggest and it looked as if nothing happened because the updated texture has exactly the same appearance as the polypainted surface. I also thought is was good to have the user be sure that the update on the map is wanted and then proceed.

Essentially what each button in this set does is execute several necessary commands to accomplish one "logical" step in the process. Separating the steps in this way is reassuring to the user.

Finally, I probably should rewrite the saveUV button to include a popup that asks if the user wants to copy the current texture map onto the polymesh to accommodate the situation you point out. If I do, I'll post the new plugin version and expand the instructions.

[edit - the updated version of the polypainting plugin SaveUV Button now asks if you want to transfer the texture map colors to the polymesh - and has been posted in the first message of this thread. ]

Again, thanks for pointing this out. Very helpful!

Sven

calum5ZB
08-14-07, 03:44 PM
Thankyou!!!!:tu:

artstorm
08-14-07, 05:52 PM
Thank you a thousand times for this one. I just got into starting painting in ZBrush and the constant switching to keep my uvs where driving me nuts. This just works like a breeze. Excellent job! :D

pawn_9
08-15-07, 06:46 AM
First I want to thx you for this great plugin . now it part of my
workflow .
I have one question though . why does we need to save the uv out .
and disable the uv for poly painting (I just can't understand that part)

Thx in Advanged

Svengali
08-15-07, 07:48 AM
I have one question though . why does we need to save the uv out .
and disable the uv for poly painting (I just can't understand that part)

According to Pixologic, if you are going to use other texture maps during the polypainting process you must delete UVs. Otherwise, when you choose any texture map to paint with, that texture is displayed on the polymesh object covering up what you are polypainting.

As for why I save the UVs out to a temp 0BJ file? If they are removed, you ned to bring them back from somewhere. In my experience creating the temp OBJ file is a more stable and reliable way to recover UVs for your model than reloading the original OBJ object.

As I said at the beginning... this plugin doesn't do anything special except streamline and simplify the process, so a user can focus on polypainting and the generation of a texture map.

Thanks for using the PolyPainting plugin. :D

Sven

pawn_9
08-15-07, 11:05 AM
Thx Sven :)
For the Explaination and for all the great plugins you released .
everyday I learn something new about Zbrush . it's just amazing .

and again Thx alot .

Anatom
08-15-07, 12:51 PM
Dear Svengali,

I am humbly asking you if you could write a lesson to demonstrate
this very plugin.
I am not much good with this kind of editing.
Feeling out of sorts with it,

Anatom:cry:

Svengali
08-15-07, 04:51 PM
Anatom,

Really, I'm not sure I could add much to the five steps I outline in the first post but I can highly recommend the Wiki page on polypainting where several people invested a lot of time and knowledge in explaining the whole process and the reasons behind it.

You can find that >>> Here <<< (http://www.zbrush.info/docs/index.php/Paint_It%21) .

Sven

Atwooki
08-16-07, 11:25 AM
Sven - Got to just say: this is SUCH a great time-saver buddy - and most intuitive also.... thanks again :) :tu: :tu: :tu:

Chris

Svengali
08-16-07, 02:18 PM
Atwooki,

Music to my ears... :D Exactly what I meant this plugin to do.

Again, thanks everyone for the feedback.

Sven

Anatom
08-16-07, 11:08 PM
Dear Sven,

Thanks for recommending me to browse towards Viki site about painting. I got it.
Just bewildered if Projection Master is that needed in ZB 3.1 ...
:D Anatom

Svengali
08-17-07, 08:58 AM
Just bewildered if Projection Master is that needed in ZB 3.1 ...


Hi Anatom,

There are several things to remember when PolyPainting in ZBrush 3:

1. You can only apply new color by painting directly on the PolyMesh in edit mode. You cannot paint on a texture mapped PolyMesh in edit mode the way you could in ZBrush 2. (In fact, if you try to paint on the texture map, you are really painting unseen, underneath, on the polymesh, which you will only see after removing the texture map... so be careful!)

This painting restriction in ZBrush 3 explains why you must paint on the polymesh itself, THEN transfer the colors (using the Col>Txr command) to the texture map - My PolyPainting Plugin tries to make the whole process of painting and copying a little easier so you don't have to remember all the individual little steps.

2. The only exception to the the rule about NOT painting DIRECTLY on the texture map is when you use Projection Master. Once you "drop" your texture mapped polymesh inside Projection Master, you CAN paint DIRECTLY on the texture map just the same as you could in ZBrush 2. The other huge benefit with Projection Master is that you can also use all the wonderful 2D brushes on the dropped model. Then, when you "pick up" your model from inside Projection Master your changes are applied to the texture map.

BTW, you can also drop a PolyPainted mesh WITHOUT a texture map into Projection Master so you can use the full range of wonderful 2D brushes directly on the polypainted mesh. When you are done in Projection Master, the PolyPainted PolyMesh you pick up is updated.

3. Finally, remember to keep the painted polygon resolution on the PolyMesh high because each polygon can only display one color. (Just as each pixel in a Texture Map can only display one color.) That is why Aurick keeps preaching that the number of polygons on your painted polymesh should more or less equal the number of pixels on the texture map you transfer the polypainting to.

In summary, use Projection Master when you want to paint on the actual texture map and when you want to paint using the various 2D brushes, be it on a texture map or directly on the painted polygons.

I hope this helps more than it confuses the issue. :)
Sven

Anatom
08-17-07, 01:18 PM
Thanks a lot for this explanation, Sven.

It's great to have you nearby!
:D
Anatom

gendragon
08-19-07, 10:48 AM
Thanks a lot! Cool plugin. :D


Anderson Soares

calum5ZB
08-19-07, 03:52 PM
Sven..just read through your message to anatom and I am simply adding my thanks for your explinations on everything.I couldnt see what the pm was for with polypainting and alpha painting now available in 3. It makes more sense now,cheers.

cal

emdee
08-22-07, 09:35 PM
Nvidia QuadroFxGo1000
Dell Latitude M60 1.7 GHz
2 GB RAM

When I step through the plugin and get to the step of "Polypaint to Texture Map" I get the attached jpeg or the object completely disappears. I have updated my graphics drivers. Any suggestions?

Thanks

skullbeast
08-22-07, 09:40 PM
Thanks!!

Svengali
08-22-07, 10:15 PM
When I step through the plugin and get to the step of "Polypaint to Texture Map" I get the attached jpeg or the object completely disappears. I have updated my graphics drivers. Any suggestions?
Thanks

Hi emdee,

This black silhouette is the classic result when you try to apply polypaint to a texture map from a polymesh that doesn't have proper UV mapping.

Try this with your polypainted model in edit mode:

Under TOOL:Texture, click on AUV. (you will have to set TOOL:Geometry:SDiv slider to 1, first). ZBrush will apply UV mapping to your model.

Now, be sure your texture map is selected and simply click the PolyPainting buttons in this order:

1. Click SaveUV button - when it asks if you "Initialize PolyMesh with Texture Map colors?" ANSWER NO...

2. Click HideMap button and you should see your polypainting on the polymesh. If you didn't save your model with the polypainting intact, apply new polypainting until you are satisfied...

3. Click ShowMap button and you should see the original texture map reloaded.

4. Click PolyPaint to TexMap button and your polypainting will be transferred to the texture map.

Sven

emdee
08-23-07, 01:18 PM
Thanks Sven. Will try it later this evening.

emdee
08-23-07, 08:31 PM
Sven,

Thanks much. That was the problem.

emdee

SNARK
09-03-07, 09:15 AM
Svengali, thanks for the cool plug-in.

I load my model with ZBrush AUV’s applied and when I get to step 3 and Hide Map, my model turns jet black. Thoughts?

Should my UV's be applied after sculpting but before mapping? That's how I'm approaching it right now.

How do you choose between GUV's and AUV's?

I think I'm just not applying the UV's in the proper point of the workflow.
When I include the step suggested by Eddy Loonstijn then go to your plugin, the ‘Save UV’ button is unavailable. Only Hide Map is available. He suggests first going to Tools>Texture and hitting the txr>col button before going to the plugin for ‘Save UV’. When I do this, the button is greyed out. I know I am missing something simple.

Is there a way to ‘Clear UV’s’ so I can be sure I’m starting from scratch?

~S.~

zsub
09-11-07, 04:24 PM
great tool!

CaptanHook
09-12-07, 05:22 AM
Reads very good, is this Just for version 3 or will it work in 3.1 too ??? I jumped ahead and put it in 3.1, opps now I can`t get online Help and the start up screen bits ( not really needed now ) have vanished. Prob a , Coincidence expect I`ve made a boob........help

Svengali
09-12-07, 06:43 AM
Snark,

To clear UVs, press TOOL>Texture>Disable UV button (but first be sure you want to do that.) :)

As to using the buttons: The NewMap button is optional - lets you make a fresh map if you need one. The other buttons are meant to be used in the specified order. 2,3,4,5 and then loop 3,4,5 as needed until you have the texture map you want.

In fact, the buttons don't do anything beyond what you would otherwise step through manually. Each of the buttons performs one "logical" group of operations. So to use any of these buttons you need to use ALL of them in the RIGHT order. ;)

Hook,
The PolyPainting button set works well in 3.1. Any other problems would be unrelated to the PolyPainting plugin. :cry:

Sven

CaptanHook
09-12-07, 12:06 PM
"Svengali , yes me harty, guess you be right there" . As when I shut down and restarted, ..blow me, twas if nothin ad appened at all. Works like a dream...........Thank you:tu: :tu: :tu:

pawn_9
09-15-07, 09:12 AM
Hey Sven , Thx for this plugs it's speed up my workflow a lot .
is it possible to make all the botton live . and not by going the 123 steps ?
for example :
I have a polypaint object and I want to assign a new map and press
"the polypaint to tecture" and not to go through the saveuv ....hide map..
and than press polypaint to texture.

I know it's not that important but just hope it could be done .
Thx in advange

Pawn

Svengali
09-15-07, 05:46 PM
P,

Actually, that's what the original Tool:Texture:Col>Txr button already does, doesn't it?

Sven

pawn_9
09-15-07, 06:33 PM
yeh... I know , That's why I said it's not that important .
but Thx again for the plug and the reply .

marciani
09-18-07, 01:03 AM
Thx man, it's so easy now............

Bye
leo

seanforsyth
02-05-08, 01:47 AM
After struggling with all these finicky steps and constantly getting it wrong, I'd like to thank you profusely for making the whole process the way it should be - easy! No more inexplicably black textures, no more having to remember lots of little steps to do something so simple. Thank you!!!

bisenberger
02-15-08, 08:36 PM
Hi Svengali,

I've been playing around with your polypainting plugin and it makes painting textures so much easier.

Thanks,
bisenberger

DanRoberts
02-21-08, 05:00 AM
This is very usefull ... thx much. :cool: