ZBrushCentral

Question: Does [CanvasStroke,()] carry its own z intensity information

I can’t seem to override the z intensity of the following statement.


[CanvasStroke,(ZObjStrokeV03n40%P1E0P168PNNN-
1sF3F440sF3F440sF3F440Z=YH12EV250K1Xh12E80v24B40h12EE0v24730h130A8v23DE4h131FEv235EBh133FEv223B0h1353Ev20F84h1

362Fv1F523h136E3v1DD1Ah1392Av1B093h13A9Fv18E6Eh13A77v15C13h13A59v1358Eh138C3v1076Ah13792vE410h1426DvC90Ch14E12

vB509h1760DvAB86h1AC0AvA665h1D647vA28Bh1FD75v9FE8h21BD8v9DEEh244E2v9CF2h267A9vC7F6h2817FvEAF8h2949Fv115BAh2A2F

7v1374Bh2AAF9v16AF8h2B0FBv192BAh2B27Cv1C1CCh2A09Dv1EC59h28D36v20CC2h27328v224D2h25E9Ev236DDh23A36v239E6h21C69v

2332Ch2078Ev1F361Yh1F7EBv1C2C9KXh1EC70v19596h1E3D4v173B1)]


I have attempted to use [ISet,Draw: Z Intensity,10] with a number of values from 1-100. Playback remains the same regardless.

If there is a description of the shorthand in the [canvasStroke,()] command that would help me decifer and edit it, please point me in the right direction.

Just for clearity, this is a recording of a smoothing operation.

Thanks,

Rich

I suspect that the problem is that you used the Shift key to switch to Smooth. That means that the Smooth intensity remains at its default which is 100.

Try adding this code before your CanvasStroke:


[VarSet,tmpZInt,[IGet,Draw:Z Intensity]]//stores current Z Intensity
[VarSet,tmpbrush,[IGet,Brush:ItemInfo]]//stores current brush
[IPress,Brush:Smooth]
[ISet,Draw:Z Intensity,10]//set to the smooth intensity you want
[ISet,Brush:ItemInfo,#tmpbrush]//restores brush
[ISet,Draw:Z Intensity,#tmpZInt]//restores Z Intensity

HTH,

I found I could bypass the brush entirely for a global smooth that I was trying to achieve. by using the deformation menu and looping it a number of times based on user input.

However, I am (was) getting my code from a recorded session. Where is the “shift” defined in the [CanvasStroke]? It plays back, shift and all. And if I was to use the code you suggest, wouldnt changing the brush fail to work anyway because “shift” is defined?

side note: Also I recorded a test of holding down shift and setting z intensity diferently… The recorded result of the z intensity being set was the same for one not shifted…
That’s why I think there is something in the [CanvasStroke] defining it.

Next time I do something like this that may be adjusted later with user input, I will either do it in a layer or use the smooth brush explicity as you suggest.

Thank you. I like that you stored the values to call back later.

All of my code needs to be put before the CanvasStroke. What it does is set the Z Intensity for the Smooth brush and then switch back to the selected brush before the stroke data is played. So it should smooth irrespective of which brush is selected.

Modifier keys used to be indicated in the stroke data with a K but that seems to have changed with ZB 3.1. After a quick look, I’m afraid I can’t see where they are.

Changing the Z Intensity for (say) the Standard brush, only affects the Standard brush, whether you press Shift or not. The Z Intensity for Smooth will stay at 100 (the default) until you switch to the Smooth brush and then adjust it.

Cool!

Thank you for the explanation! That clarification will repeatedly come in handy!

:slight_smile:

Rich

You know that you can record stroke data on the fly by using the controls in the Stroke : Inventory submenu? You can export the results as a text file that can then be loaded back in when you want it, using StrokeLoad/StrokesLoad.

One small caveat: if you load a stroke/strokes in this way you need to save to and load from two different file names alternately. For some reason if you load from a single file name the stroke doesn’t change although the file may have been updated.

HTH,