Attribute Promote SOP を利用して 最小/最大/平均 などを計算
2022-06-25 #Blog #SopJoy
任意のAttribute の最小・最大・平均などを計算したいとき, いちいち VEX で loop などを書かなくとも Attribute Promote SOP.iconAttribute Promote SOP で計算結果を Detail Attribute に保存することができる
https://gyazo.com/982b2549543270bcaa5167783312f3cahttps://gyazo.com/d110e612144bc1855b8cf2e587c93f5e
New Class を Detail として Promotion Method を計算したいものにする
https://gyazo.com/7e6bba6d6eb101c7723b72ae4009b912https://gyazo.com/53dc5818f1935846d4c73788683d0548
vector type などであっても要素ごとに平均をとってくれたりする
Change New Name Delete Original のチェックボックスを上記のようにすることで元の値はいじらずに計算だけ行うような挙動となる
Labs Min Max Average SOP
この機能を type で明言している Op として Labs Min Max Average SOP.iconLabs Min Max Average SOP というものが存在している
Attribute Promote SOP の Wrapper で UX が専用のものになっており使いやすい
See also
soptoolutils.computeRange 関数で Attribute の 最小/最大値を計算