1// --------------------------------------------------------------------------- 2// Project: NintendoWare 3// File: demo_Common.vsh 4// 5// Copyright (C)2009-2010 Nintendo Co., Ltd. All rights reserved. 6// 7// These coded instructions, statements, and computer programs contain 8// proprietary information of Nintendo of America Inc. and/or Nintendo 9// Company Ltd., and are protected by Federal copyright law. They may 10// not be disclosed to third parties or copied or duplicated in any form, 11// in whole or in part, without the prior written consent of Nintendo. 12// 13// $Revision: 11329 $ 14// --------------------------------------------------------------------------- 15 16// Input registers map 17#define aPosition v0 18#define aColor v1 19#define aTexCoord v2 20#define aOffset v3 21 22// Output registers map 23#define vPosition o0 24#define vFrontColor o1 25#define vTexCoord0 o2 26 27#define CONST c95 28def CONST, 0.0, 0.5, 1.0, 2.0 29 30 31#define tmpView r15 32#define cProjMtx c0 33#define cViewMtx c4 34#define tmpPos r0 35 36#pragma bind_symbol( aPosition.xyz, v0, v0 ) 37#pragma bind_symbol( aColor, v1, v1 ) 38#pragma bind_symbol( aOffset, v3, v3 ) 39 40#pragma bind_symbol( uProjection, c0, c3 ) 41#pragma bind_symbol( uModelView, c4, c7 ) 42 43#pragma output_map ( position, o0 ) 44#pragma output_map ( color, o1 ) 45//#pragma output_map ( texture0, o2.xy ) 46 47 48// �N���b�v���W��Z�͈̔͂́A���炩����[0, -w]�Ƃ��Ďˉe�s�������B 49main: 50 mov tmpPos, aPosition 51 add tmpPos, tmpPos, aOffset 52 m4x4 tmpView, tmpPos, cViewMtx 53 mov tmpView.w, CONST.z 54 m4x4 vPosition, tmpView, cProjMtx 55 56 mov o1, aColor 57// mov vTexCoord0.xy, aTexCoord 58 end 59endmain: 60 61