ForEachLoop
main mel draw photography about

ForEachLoop

 


 

Procedure Texture

3D - No Comments » - Posted on August, 6 at 11:30 pm

I spent few days to try out Allegorithmic“MaPZone” to create a procedure texture, MapZone is freeware to create texture, but you need a Pro version to output the datas to game engine. It’s not easy to learn, an artist would find rather frustrated  by combining bunch of different nodes to get a texture result that they want. However, the result you could get is actually quite good if you know what you are doing. Tile texture is easier than making a special mapping texture, this would require higher level knowledge of the software. Best thing about procedure texture is that it can give the prgrammers the datas that generates the texture and able to create a big scene that less than 500k texture memory. In short, if you want to make a next-gen good looking game on a downloadable platform that less than a 100M, procedure texture is the better option. Here is the rusted texture I created.

Zbrush : Normal + Displacement Map in Maya

3D - No Comments » - Posted on July, 30 at 1:18 pm

So I generated the normal map and displacement map from Maya using “Transfer Map”. I later combined both of the maps under one material and did some tweaks. The final rendered result is very close to the original Zbrush hi-res model, this method is very suitable for game, to get hi-res model look from a lo-res model.


Zbrush : WIP 02

3D - No Comments » - Posted on July, 28 at 7:18 pm

Added rough skin on Zbrush. Next step I will generate a normal map to render with the low res model.

Zbrush : Work in Progress

3D - No Comments » - Posted on July, 28 at 10:00 am

Im currently adding details on the monster head that I modelled. Here’s a screenshot, will update again when it’s done.

For Each Loop is BACK.

3D - No Comments » - Posted on July, 14 at 9:13 am

My website is fully functional again after updating the new look the last week! Stay tune for more posts!

Thanks

Sin

Reverse Foot IK

Rig - No Comments » - Posted on March, 9 at 1:28 am

reversefootik

Reverse Foot IK setup has similar idea with Reverse Foot Lock setup but it requires less bones. Number of bone is one of the factors in game making that could affect the game memory, and the programmers can allow a certain limit of joint number you are not happy with, but we gotta live with it :) .

Ok, first create 3 IK handles from the 1) hip > ankle, 2) ankle > ball, 3) ball > toe. Name them to ankle_ik, toe_ik and toeend_ik respectively. ikRPsolver is used for the IK handles.

The following steps demonstrate how to create a Reverse Foot method.

A) Group (ctrl+g) the ankle_ik itself and call it ball_grp. Hit “insert” to allow you to move the ball_grp pivot point from origin to the ball joint. This group will control the ball of the foot.

Read the rest of this entry »

Animation and Pose Copy Tool…with a batch transfer

Mel Scripting - No Comments » - Posted on February, 10 at 9:11 am

anm copyThe “Animation Copy” allow Maya users (tested in Maya 7) to record the pose, or animation in a text file that stored in a directory the users have picked; the directory the users picked will be recorded down(in anmPose_userPrefs.mel) so users don’t have to go in to pick the directory again next time they start the tool. You could also type the directory path in the directory textfield and press “Enter” on the numpad to save the directory info. Pose and Animation keys are stored in .pose and .anm respectively to distinguish the format, users can open the file with notepad and edit the key datas as they want.
The script is copying and pasting the animation keys based on the name of the nodes,
so identical node names are required to get the keys transfered/copied over.

The second function in this toolset is the “Animation Transfer”, it works differently from the above mentioned. This script can do a batch transfer of animation keys to a different character that have the same node names.

(Read more..)

Create Cluster

Mel Scripting - 1 Comment » - Posted on February, 4 at 9:54 pm

cluster.jpg

In Maya, once you create a cluster, it will return to object mode, then you will have to go back to component mode and create a second cluster. this is very frustrated, so I always have this simple script in my tool set to create clusters faster, one and another one without going back to object mode back and forth.

 

 

 

 

(Read more..)

特训 Texun (Special Training)

3D - No Comments » - Posted on February, 1 at 10:24 am

texun-1

特训, probably means “Special Training” from what I understand from the Kanji characters. It is a little game (only 28k) I played few years ago and just found it back from the net. From the pictures, you see there are a lot of bullets and a little ship, you may think this is another vertical scrolling shooting game, well, it is not.

(Read more..)

Align two objects

Mel Scripting - 2 Comments » - Posted on January, 31 at 4:01 pm

Description: This simple script could help you align 2 objects together. I put an option you could turn on if you like the object to be orientated as well. First, select the target object which you want to align to and then shift select the object that will get aligned.

 

 

 

 

(Read more..)

Water color

3D - 2 Comments » - Posted on January, 28 at 8:42 pm

water color

I made this water color painting while ago, I will paint more when I have more spare time.

Rename Duplicates

Mel Scripting - No Comments » - Posted on January, 11 at 6:27 pm

Description : This script will find any duplicate names in your Maya scene and rename them to a different one by adding “1″ at the end of the name. You will know if in the script editor you see a node name has been changed, otherwise there’s none. However, this script doesn’t find duplicate Shape names. Please save your works before run this script!

global proc s_renameDuplicate()
{
string $nodes[]=`ls -type transform`;
global int $count;
$count =1;
for ($x=0; $x< size($nodes); $x++ )
{
int $num_token = 0;
string $buffer[];
$num_token =`tokenize $nodes[$x] "|" $buffer`;
if ($num_token > 1)
{
while ($num_token > 1)
{
string $name =($buffer[size($buffer)-1]);
rename $nodes[$x] ($name + $count);
print ("renamed " + $nodes[$x] + " to " + ($name + $count) + "\n");
//$count++;
$nodes =`ls -type transform`;
string $buffer[];
$num_token =`tokenize $nodes[$x] "|" $buffer`;
}
}
}
}

Set Normal Size

Mel Scripting - No Comments » - Posted on January, 11 at 6:23 pm

Descriptions: This script will set the length of the normals by adjusting the slider on a window, and toggle the normals on and off.

 

 

 

 

 

 

global proc setNormalSizeProc()
{
$normalSize = `floatSlider -q -value setNormalSizeFS` ;
setNormalsSize $normalSize;
print ("Normals size :" + $normalSize);
}
//Sample of a window you could use.
if (`window -exists setNorWindow`)
{
deleteUI setNorWindow;
}
window -t "Set Normals Size" setNorWindow;
rowLayout -nc 2 -cw2 64 64;
button -bgc 0.627 0.6 0.872 -w 64 -h 22 -l " Normal" -command "ToggleFaceNormals";
floatSlider -w 64 -min 0 -max 1 -value .5 -step .1 -dc "setNormalSizeProc" setNormalSizeFS;
setParent..;
showWindow setNorWindow;

Round Float Values

Mel Scripting - 2 Comments » - Posted on January, 11 at 10:23 am

Descriptions: In Maya 7, if you want to round a float value shorter to 3 decimals or whatever you like, the following is one of the solutions; convert the float to an interger, multiply with 1000 (if you want 3 decimals), add 0.0005 to round out the value, at the end divided it by 1000 again.

//convert to (integer), add 0.0005 and multiply with 1000

float $floatValue = 0.1234567891;

$floatValue = (int) (($floatValue + 0.0005) *1000);

//devide it back

$floarValue = ($floatValue / 1000);

//to print out the result, which is 0.123

print $floarValue;

Joint Count Hud

Mel Scripting - No Comments » - Posted on January, 10 at 5:59 pm

Description : This hud is only useful for riggers who need to know the number of joints for their characters, if the game engine has limited the joint numbers.Type “HudJointCountProc” after sourcing the scripts below.

 

 

 

 

 

 

 

 

 

global proc int s_jointCountProc()
{
string $allJoints[] = `ls -type joint`;
return (size($allJoints));
}
global proc HudJointCountProc()
{
string $jointCountExists;
if (`headsUpDisplay -ex HUDJointCount`)
{
headsUpDisplay -rem HUDJointCount;
}else
{
int $jointbb = `headsUpDisplay -nfb 0`;
headsUpDisplay
-section 0
-block $jointbb-blockSize "small"
-label "Joints:"
-labelFontSize "small"
-command "s_jointCountProc()"
-event "SelectionChanged"
-nodeChanges "attributeChange" HUDJointCount;
}
}