EZBBHair



  • Okay, I'm nearly ready to roll out EZBBHair v0.1 here's a screen shot of what I've got so far, it all seems to work except that the mats look white in preview until you go into the material window, must be missing a update type cal, but it renders okay.

    Hopefully will have a release sometime tomorrow for people to test

    0_1492301198150_upload-ca38e6c5-2f4e-4dd8-9934-f0ed9c83bbb8

    Amanda



  • @amethystpendant I look forward to playing with it Amanda.



  • I am, too. Thank you for your hard work on this, @amethystpendant !



  • I think the mat looking white is a poser bug. I get stuff like that with just copy and paste.



  • @redphantom said in EZBBHair:

    I think the mat looking white is a poser bug. I get stuff like that with just copy and paste.

    You solve it by using the menu option Render / Reload Textures



  • Okay Version 0.1 Build 1 of EZBBHair is available. This helps implement the hair shader created by @bagginsbill in We need a hair shader like this for Poser ... Shader gurus? and is based on code created by @Snarlygribbly

    Quick tour

    The presets and button are exactly the same as in EZCloth.

    As you change selection the Actor and Figure labels should change. Also the ckeck box list will fill with the relevant materials of either the figure if the actor is a body part or the actor. Simply check the material zones you want to apply the shader to.

    To avoid me having to hand build the material, you need to select @bagginsbill's material file (I've included a copy in the Zip as I made a small change, and BB's was zipped) Just click on the ellipses and browse to the file.

    the Main tab lists the variables (The same as BB uses but with the PM: and PMC: prefixes removed and Colour spelt correctly ;o) Also I added Specular Colour 1 as a PM: variable in the attached mat file as I use that if I have black hair and make the spec a little blue for artistic effect. If your mat file doesn't have this variable it will be ignored

    Once you have made your changes to the variables, or just go with the defaults or a previously saved preset, press the Apply button and it will update the selected materials copying the trans and colour maps across to the new mat. The figure might look transparent and white after applying, but it will render okay. Select Rrender / Reload Textures to view in preview if this happens. I hope to fix this in the next build, which again thanks to @Snarlygribbly might not need the mat file. I may also do an addin for EZSkin3 at some point, but for now this does what I need it to do, but wanted to share.

    Any bugs, please post here.

    Hope you find it useful, if you do let me know ;o)



  • Version 0.1 Build 2 now available, this fixes the preview being white after the material is applied (Found in @Snarlygribbly's EZSkin3 code whilst looking to make this an EZSkin3 addin!)

    Amanda



  • Right, BB SuperrFly Hair is an EZSkin3 plugin that does what EZBBHair does, but will be easier to maintain so I would suggest that if anyone wants this functionality you use this plugin rather than the EZBBHair as I will not be doing any more work on the original.

    Amanda



  • @amethystpendant Thank you, amethyst!

    But, for us dummies, how does one go about plugging in this plugin to EZSkin3?



  • @Glitterati3D In EZSkin3, click on the options button 0_1492436157529_upload-31f5de48-36e6-426e-87d7-83c692bd696a
    Then in the options window, click on the browse button next to the Custom shader engines.

    0_1492436119012_upload-6cafeb05-f117-406a-b52a-4047126f9ebd

    Browse to a folder that will contain your plugins (mine is a subfolder called "Custom shaders" below the folder were the EZSkin3.py is stored, but it can be a any path on your machine. Copy the "BB Superfly Hair.py" file included in the Zip I uploaded in to that folder. Then the next time you start EZSkin3 there should be a new option in the shader engine drop down on the main page
    0_1492436444313_upload-486270ac-2241-4ab6-a643-53f7fc477677
    Chances are your hair figure / prop will be "unsopported" so click on the Editor button and set your figures material zones to be bb_hair and any you want to ignore to be "ignore"
    0_1492436675913_upload-ad7b5221-eae6-4a5c-a858-8bb0d5bb9e68

    Click OK in the Editor to go back to the main page

    click on the "cfg" button to see the available parameters
    0_1492436760445_upload-241b1f87-f8e8-42c2-82be-dde66389a742

    Set the params the click OK to go back to the main window and apply



  • BTW, it is essential that you have the build 89 of EZSkin3 for the plugin to work, you can get it from @Snarlygribbly's site http://snarlygribbly.org/snarlyspace/ezskin.html



  • @amethystpendant

    Hi Amanda

    I'm getting this error,not sure what I'm doing wrong there

    Traceback (most recent call last):
    File "C:\Program Files\Smith Micro\Poser 11\Runtime\Python\poserScripts\ScriptsMenu\EZBBHair.py", line 3614, in <module>
    app = Main()
    File "C:\Program Files\Smith Micro\Poser 11\Runtime\Python\poserScripts\ScriptsMenu\EZBBHair.py", line 3547, in init
    self.ui = EZCloth(self.root, self)
    File "C:\Program Files\Smith Micro\Poser 11\Runtime\Python\poserScripts\ScriptsMenu\EZBBHair.py", line 2763, in init
    ctl.SetLabel(self.current_figure.Name())
    AttributeError: 'NoneType' object has no attribute 'Name']

    Thanks,Jura



  • @jura11 Hi, are you trying to run with no figure in the scene, or no figure selected?


  • Poser Ambassadors

    @amethystpendant
    Only issue I had was the very first time I ran it.
    It simply set the transmap and the diffuse map to none.
    Setting the textures again and all was well afterwards.
    Good work.



  • A nighttime render using the plugin on the hair.
    0_1492529092256_nighttime.jpg



  • @amethystpendant
    Yup,I've tried to run with no figure,added figure and hair and voila everything is working,thanks again for yours help Amanda

    Thanks,Jura



  • Thanks this is great.



  • Brilliant script! great to see BB and Snarly performing their magic still! :)

    I've sort-of been trying to create some solutions for work, for which I'm learning Angular 2. Not your grand-dad's Javascript, definitely. Between that and my usual clinical work, not much time for fun stuff. Had a go with EZ-Skin3 and BB-SuperrFly shader. Works a treat as long as you have hair objects selected. I did get this error:

    Traceback (most recent call last):
    File "E:\POSER\EZSkin 3\EZSkin3.py", line 5612, in Apply
    File "C:\Users\Public\Documents\Poser 11 Content\Runtime\Python\poserScripts\ScriptsMenu\EZSkin\BBHairShader\BB SuperrFly Hair.py", line 84, in BuildShader
    method(mat, p)
    File "C:\Users\Public\Documents\Poser 11 Content\Runtime\Python\poserScripts\ScriptsMenu\EZSkin\BBHairShader\BB SuperrFly Hair.py", line 187, in MakeBBHair
    TranImage=mat.GetMap('transparency').InputByInternalName('Image_Source').Value()
    AttributeError: 'NoneType' object has no attribute 'InputByInternalName'

    but perhaps it because I was trying to apply a hair shader to a hair clip. When I set that and Preview to ignore, the script ran happily.

    My, what an elegant shader! Dunno how long I tried to produce something nice, myself... I know I spent days and days coding those "shaders". But this? blows all of that completely away. Now, if only I can cobble together something similar for Blender... ;-)



  • Hi @RobynsVeil glad you found it useful. I've uploaded a new version that will deal with the error you got when the shader you were working on did not have a transparency. New BB SuperrFly Hair Plugin



  • @amethystpendant I've very impressed, AmethystP, thank you very, very much!

    ...(not to mention envious... I'm trying to get my head around Angular 2 -- taking a Udemy Course -- and I'm finding TypeScript rough going, so much prefer Python!) :-/