############################################################### # # 조합될 쉐이더의 공통 머릿부분 # Local Index 공통사용 # 0 : BodyLight # 1,2,3 : 상수 (텍스쳐 공간에서 사용) # 3 : Model World Position # 4 : x) Model Scale, y) BoneScale # 5 : Direction of Light Source # ############################################################### #!Start #0. 기본 !!ARBvp1.0 PARAM Mvp[4] = { state.matrix.mvp }; PARAM Mv[4] = { state.matrix.modelview }; PARAM EtcConsts = { 1.0, 0.0, 0.5, 0.0 }; PARAM LocalParam[10] = { program.local[0..9] }; PARAM EnvParam[196] = { program.env[0..195] }; TEMP RST_NORMAL, FINAL_VERTEX, Temp, Temp1, Temp2; ADDRESS Addr; OUTPUT RST_POS = result.position; OUTPUT RST_COLOR = result.color.primary; OUTPUT RST_COLOR_SEC = result.color.secondary; OUTPUT RST_TEXTURE = result.texcoord; #임시적으로!... ATTRIB IPT_POS = vertex.position; ATTRIB IPT_NORM = vertex.normal; ATTRIB IPT_TEX = vertex.color; ATTRIB IPT_COLOR = vertex.color; #!End ##################################################################################### #!Start #1. 2 - texture !!ARBvp1.0 PARAM Mvp[4] = { state.matrix.mvp }; PARAM Mv[4] = { state.matrix.modelview }; PARAM EtcConsts = { 1.0, 0.0, 0.5, 0.0 }; PARAM LocalParam[10] = { program.local[0..9] }; PARAM EnvParam[196] = { program.env[0..195] }; TEMP RST_NORMAL, FINAL_VERTEX, Temp, Temp1, Temp2; ADDRESS Addr; OUTPUT RST_POS = result.position; OUTPUT RST_COLOR = result.color.primary; OUTPUT RST_COLOR_SEC = result.color.secondary; OUTPUT RST_TEXTURE_DEF = result.texcoord[0]; OUTPUT RST_TEXTURE = result.texcoord[1]; #임시적으로!... ATTRIB IPT_POS = vertex.position; ATTRIB IPT_NORM = vertex.normal; ATTRIB IPT_TEX = vertex.color; ATTRIB IPT_COLOR = vertex.color; #!End #####################################################################################