[Custom Build] Blender 2.79.6 Weighted Normals & Customized modifiers

(cgstrive) #1

Hey

Would like to share a custom build that includes all the latest 2.79.6 features (AO, Bevel etc), Weighted Normals modifiers by Rohan Rathi and several hackish modifiers by myself that have gone through quite a lot of production (gamedev). These include:

UV Warp modifier

  • Without From To targets set, it defaults to UV OFFSET mode (similar to Array, Mirror). Mainly useful for Gamedev where you have multiple instances sharing same UV space which would cause an error when baked (instead uv can be shifted by +1 ). It’s also useful for animation.

  • With “S” detected in modifier name, it will SCALE UV instead of offset. This is extremely useful when working with thickened CURVES for things like Wires, Ropes etc where Textures need to tile:

Displace, Bevel modifiers have been altered to work with Thickened Curves.

Build modifier can be renamed to “Weld” resulting in remove doubles functionality. For myself I use it with Bevel after Boolean workflow as it reduces some errors. To my understanding 2.8 Bevel might have it built in.

Split normals modifier can be used to Amplify normals. This is very useful when working with game geometry (in particular holes, screws etc) and strong parallels can be drawn to DECALS workflow.

For example suppose you need a hole in your geometry - you can cut a Sphere in half and export for Bake in SP. You will have to use very large bake distance that will likely cause artifacts elsewhere on bake and AO map, Position etc will all be messed up. With such workflow it’s easy to avoid and all bakes come out nicely.

EdgeSplit modifier:

  • Can be used to MARK SHARP EDGES only, similar to Auto Smoothing angle. This is useful for game assets when working with Booleans and Weighted Normals modifier and some other cases. It would be possible to just use EdgeSplit, but it would do the actual SPLIT (instead of marking Sharp) which would be flagged as manifold geometry in gamedev pipelines.

  • EdgeSplit can split edges marked as SEAMS when no checkboxes are set. Why? Depending on modifier combination SEAMS can be more stable and survive towards the end of the stack. There are also instances where

Additional features:

  • image helpers do not have a border (nice if you keep reference in viewport)
  • seams+sharp edges have Unique color. Before could not tell
  • Image Editor will not show UV if “pin” is enabled. This is useful when you like to have multiple image viewers open as reference (as i do). Prior when working with HP this was the result:
    http://cgstrive.com/SS/2_892018_f036.png
  • Boolean can be used on Text objects

Example of Displace on Curve with UV scaling:

Example of Triangulate Ngeons:

Example of UV scaling on Curves used on wires to tile Texture. Also Displace on Curve is Blue part (Voronoi):

Example of Amplified Normals_:

Example of first splitting SHARP edges, then Seams:

BUILD IS AVAILABLE HERE: http://cgstrive.com/blender/Blender2_79_6_wn_cgs.rar

Usage: As can be read above most alternative modifier functionality is triggered by altering it’s name (strstr()). It is not quite as intuitive as some would like(e.g separate modifiers), but most of this functionality was created for personal use as experimental. To maintain separate individual modifiers would require 10x the work. Snippets are usually in modifier name.

Please consider that these features are experimental. If you plan to render it with renderfarm, share or open with different blender ver, work that uses custom functionality will be lost unless collapsed.

/////
Motive: I am hopeful that if this catches glimpse of developers, then these features can be integrated professionally into official build. Most of these modifications are a few lines of code and would most likely take a few hours for professional Blender developer to do decently.

Few more ideas I would like to attempt later or requests if someone is kind enough to take a jab at them:

  • SubDiv modifier should accept Vertex Groups. Localizing detailing is very useful (e.g damaged corners of a wall)
  • Array should have Radial Array option
  • Solidify could have “only sides” option
  • Remesher with OpenVDB. Not only useful for fluid sims, but also Organic booleans:
    https://www.youtube.com/watch?v=AVRYWCtRyCw

Hope it’s helpful.

31 Likes
OpenVDB remesh
Will blender 2.79b get a cycles edition?
Pie Menu Editor 1.15.20
MESHmachine
Speedflow
Creative Bundle Add-on Package
(Pitiwazou) #2

I love it, made 2 videos about that build!


3 Likes
(Zuorion) #3

Maybe you could use Circular Array modifier code?
https://developer.blender.org/D3206

1 Like
(Charlie) #4

Circular Array Modifier is not accepted, see:
Modifiers that Instance Geometry
https://wiki.blender.org/wiki/Reference/AntiFeatures

1 Like
(Yury Ziankouski) #5

You’re my hero! Thanks for sharing, gonna use it daily.

Hmmm, for some reasons I cannot change the windows layout by dragging corner. Gotta be the issue with some
addons

(cgstrive) #6

Thank you ZenYS. No idea why, works fine here.

Here’s another example how Triangulate Ngeons makes it possible to add SubDiv modifier post Boolean:


In Left case no TriangulateN(geon), on right with it.

@gorion103, Charlie. Thank you for sharing the Circular Array link, it could come handy! I had already managed it once, but reverted to using Python script for compatibility reasons, which is why I think Circular Array should be official feature as most users have to do this timeconsumingly and manually.

For example, imagine setting this up without a single script:


How long would it take you? How long would it take a new user? Personally:

  • If i’d have to model it SubD we’re talking at least 30 minutes if done decently.
  • If I would have to set array up manually to use Object as rotational pivot - 15 minutes
  • If there would be a checkbox “Circular” in Array modifier - 2 minutes

As such it is surprising to see it as anti-feature as we already have Array modifier(that is amazing), the only question is “circular” duplication pattern (which can be painstakingly achieved already with dummy object cluttering the scene). The argument is really about adding a few new knobs in Array modifier to make blender more user friendly and productive.

7 Likes
(rawalanche) #7

Yes, for me, it’s very perplexing that Blender has an array modifier (one of the most used modifiers) but it does not have circular/radial mode. It’s an essential feature any array distribution feature should have. I am having really hard time understanding how it could be omitted in the first place, and we actually ended up needing a 3rd party hacked build for that :frowning:

EDIT: Looks like there is already entry on RightClickSelect for it here:

If anyone hasn’t voted yet, please do.

3 Likes
(drgci) #8

can you make a build with fracture modifier and the new cloth sim? with the latest blender master?

(Yury Ziankouski) #9

You’re asking for too much)

(Weisl) #10

Nice job. I really hope that the weigthed normals modifier will make it into the official releases :)! I have writen some scripts that copy the objects, apply all modifiers and than apply weighted normals before exporting or baking. This modifier makes them unecessary and simplifies my workflow!

(Pitiwazou) #11

It will be on 2.8 yes :wink:

My workflow with cgstrive’s build!



Cannot work without this triangulate modifier anymore!

1 Like
#12

Hello Jüri,
Would you mind share your build’s sources somewhere? Maybe on Github ?
I’m interested in your “hackish modifiers” code.

#13

Any news? Could you share the sources?

(cgstrive) #14

I apologize for delay, a lot on my plate. This is not github quality material nor proper, exemplary way to develop something. These “hacks” are often one-liners (e.g eModifierTypeFlag_AcceptsCVs allows modifier to work on curves, but can cause instability), changes to math such as Scaling or offsetting UV (code can be inspired by MOD_Array, Mirror) etc. This is trivial to any developer.
Instead of changing 10 files to do it properly, i just compare modifier name with “strstr” in 1 single file (MOD_*.c) and trigger alt functionality. This saves a lot of time, including with maintenance, but it’s shameful approach. After all the intent of this post was to highlight these ideas in hope some of them could be picked up by professional devs of Blender to be enjoyed by all in future blender releases. If i’d have enough confidence or time for making a patch, I would. This is not the case. If someone experienced would like to collaborate with me on similar ideas, I’d love to hear from them.

Here’s triangulate modifier, uvwarp (with shifting, scaling) and simple displace(that works on curves also) to show these simple triggers in action: http://cgstrive.com/blend/mod_hacks.rar

I would also like to thank and share Campbells great advice of using “grep” (with cygwin in windows) to quickly search through source code for examples. It has been invaluable for me. If artist is already making a custom build, one should have confidence to try their ideas and use tools like “grep”. Most of my tweaks are just a few lines.

Hope it helps.

3 Likes
#15

Thank you!
I’ll look at this.

(obsurveyor) #16

FYI the GPL Blender is licensed under requires that if you make a binary public, you must provide the source if requested.

(cgstrive) #17

Binary link removed. Requesting thread to be deleted.

(Pitiwazou) #18

cgstrive does what he can, I asked him to post his build, for sources, it’s a hack, not something correctly placed on a github, he doens’t have a github and don’t know how to do it, so what can you do to help him since you request the sources?

(obsurveyor) #19

I’d be happy to help in a couple days once I get back home from vacation. It shouldn’t been too rough since Blender is already under git.

(zanzio) #20

I don’t think it needs to be hosted on something like github in order for it to not violate the GPL. He just needs to provide the source code on request. The easiest way to make his build legal is to just package the source code with the compiled build under a folder called sources or something like that.

If he is only sharing one build, then he only needs to share the source code for that build. If he releases an updated build, then he could just package the updated source code with that build.