Update from Shanghai…
Happy Chinese New Year to all. Yeah a lot of things happened in the recent past. Long story short, Got a job in Shanghai,China(VirtuosGames) and moved here in Sept, after which my website was not accessible(Great Firewall). So I finally got a VPN Connection(StrongVPN) and my website is back.
About Shanghai, I am Loving the place and my work rocks too, but the language is little hard to learn and understand. Hope I learn it sooner or later. Will post some pics soon, till then bye..
Dotnet+Maxscript+GDI
I have been learning and using dot-net in 3ds max a lot recently. I think its time i show some of my learnings in Dot-net GDI . Here is an example of using a dot-net label as progress bar with GDI. I tried to replicate the look of pre-max9 polygon counter as asked in tech-artist.org forum(here).

( global _dupPolyCounter try (destroyDialog _dupPolyCounter) catch() rollout _dupPolyCounter "Duplicate Polycounter" width:250 ( local _min = 100,_max =200 group "Progress Test" ( label _bdgt "Budget:" pos:[20,25] spinner spn_max "" pos:[65,25] range:[100,1000,_max] width:55 type:#integer label _crnt "Current:" pos:[140,25] spinner spn_val "" pos:[185,25] range:[1,spn_max.value,_min] width:55 type:#integer dotnetcontrol lbl "label" height:10 width:200 pos:[25,50] ) local acolor = dotnetclass "system.drawing.color" mapped fn dispose gdiobj = ( gdiobj.Dispose ) on lbl Paint args do ( local margin = 2 graphics = args.graphics width = ((lbl.clientRectangle.width)/40) _val = ((float(_min)/_max)*40) X = lbl.clientRectangle.X+margin Y = lbl.clientRectangle.Y+margin for i = 1 to _val do ( rect = dotnetobject "System.Drawing.Rectangle" X Y (width-1) (lbl.clientRectangle.Height-2*margin) _col = acolor.green if i > 35 then _col = acolor.red else (if i>27 then _col = acolor.yellow else _col = acolor.green) foreBrush=dotnetobject "System.Drawing.SolidBrush" _col graphics.FillRectangle foreBrush rect X += width dispose #(foreBrush) ) ) on spn_val changed val do ( _min = val lbl.invalidate() ) on spn_max changed val do ( _max = val spn_val.range = [1,spn_max.value,_min] lbl.invalidate() ) on _dupPolyCounter open do ( lbl.backColor = lbl.backColor.Black ) ) createDialog _dupPolyCounter )
I hope to post more snippets in future..
Post Effects Vision Shader
Started learning some shader writing in HLSL and 3ds Max recently. Here is my first shader. Its a post effects shader for 3ds max. I tried to get the night vision and thermal vision effects using this shader. So here's what i have got.
You can view the same video at http://www.youtube.com/watch?v=wXxdq_mFAzg
The shader uses 2 gradient maps for Thermal Vision and Night Vision. I have added control for Black level adjustment, which controls the blackness in the scene(as shown in the video).
Currently working on Detail Normal Shader for 3ds max, will post it soon.
Self-Promotional Plug Alert!
The NormalMap Widget Script that i had created has been added to polycount wiki. Thanks EricChadwick for adding it. I have also added some decent images to the post.
Read it here – http://wiki.polycount.net/Normal_Map
Scripts release(Select Non-Planar and Broken Wall Creator)..
Lately i have got some request for the Broken Wall Creator script, so finally got time to make it releasable. It has got some bugs so please bare with it and comment here if found any. Use only the top view to create the broken wall because of some bugs.
Someone on Tech-Artist.org wanted a script to select non planar faces. I had a script that was written a while back so thought of releasing it as well.
Please download the scripts from
Broken Wall Creator
Select Non-Planar Faces
Installation Instructions for Select Non-Planar Faces
-------------------------
* Drag and Drop Select_NPR.mzp in to 3dsMax viewport.
* From the Customize User Interface menu option you can now assign Select_NPR to a Toolbar. The command is located in the "Akira Scripts" Category.
NormalMap Widget for 3ds Max
Been busy learning to create forms using dotnet in maxscript. Earlier today stumble across Steev “kobra” Kelly's tutorial for easily creating normal map details in 3ds max and use photoshop to add it to a base map. So thought of writing a script for quick normal map renders based on the tutorial.
Steps for usage:
1. Run the Script
. Find it in Customize User Interface->Toolsbar->Catogery->Akira's Scripts-> NormalWidget
2. Select the Highpoly and hit setup.
3. Scale the highpoly to fit the template plane.
4. Hit render and save the image.
5. Use it to add details in the base map. Idle to create a library of normal maps for using across objects like nuts,bolts,cracks,etc.
6.Enjoy.
Hopefully will include render size options in the next update. Suggestion are welcome.
DOWNLOAD:
NormalMapWidget
NormalMapWidget(Mirror Link)
Python in 3ds Max by BLUR..
I just found this awesome post in cgtalk(link)
by Eric Hulser,BLUR which has a complete python replacement for maxscript. This should open up many doors for scripting in 3ds max as python is more efficient language. They have also added PyQt support for making rollouts. I will try it very soon and post some updates. BLUR rocks...
Links:
Blur-Dev
Some Old Game-Art..
MentalRay Utility Gamma Adder..
This script was written for a friend who had a scene with 150 textures and wanted to add Utility Gamma & Gain(MI) for every diffuse texture. Thought this might be useful for MentalRay users out there.
Features:
- Adds Mental ray Gamma and gain utility to the diffuse map channel, only if a bitmap texture exists.
- Currently adds only for Arch and Design,Standard Material and Multi Material in the diffuse map channel.
Download Link:
http://www.scriptspot.com/3ds-max/mentalray-utility-gamma-adder
Broken Wall Generator..
Here is a little maxscript inspired from Gunnar Radeloff's demo reel(here). It generates a broken wall from an interactively drawn curve or a existing shape. Options to control wall width, no. of columns, brick width, height and length. Will be adding more features in future.