관련 색인이 없습니다.
dcl_usage (정점 셰이더)
 
Microsoft DirectX 9.0

dcl_usage (정점 셰이더)


출력 레지스터의 모든 종류는, 12 개의 12 o (출력) 레지스터에 정리한다 (2 개가 색, 8 개가 텍스처, 1 개가 위치, 1 개가 포그(안개:fog)와 포인트 사이즈). 이러한 레지스터는, 사용자에 의한 임의의 픽셀 셰이더의 보간에 사용할 수 있다. 예를 들어, 좌표, 색, 포그(안개:fog) 등이다.

출력 선언이 도입되어 거기에 따라 의미들이 각 레지스터에 할당할 수 있다. 낡은 oPos 및 oPts 는, 위치 또는 pointsize 의미들과 함께 레지스터를 선언하는 것으로 옮겨놓을 수 있다. 더 자세한 정보는, 이하로 설명한다.

12 개의 "출력" 레지스터가 있다. 그러한 중 10 개에는 4 개의 성분 (xyzw)이 있어 (반드시 o0 ~ o9 는 아니고, 임의의 10 개), 1 개는 위치로서 선언해야 한다 (4 개 모든 성분). 옵션으로, 이제 1 개는 스칼라-포인트 사이즈로 설정할 수 있다.

구문

출력 (o 레지스터)의 선언의 구문은, 입력의 선언과 유사하다.

dcl_semantics o[. write_mask]

여기서

주의

정점 셰이더의 버전3_03_sw
dcl_usagexx

dcl_usage 명령은 모두, 최초의 실행 가능 명령보다 전으로 지정해야 한다.

선언의 예

vs_3_0
dcl_color4     o3.x    // color4 is a semantic name.
dcl_texcoord3  o3.yz   // Different semantics can be packed into one register.
dcl_fog        o3.w 
dcl_tangent	   o4.xyz
dcl_positiont  o7.xyzw // positiont must be declared to some unique register 
                       //   in a vertex shader, with all 4 components.

dcl_psize	   o6      // Pointsize cannot have a mask 
                       //   (that is, mask is full . xyzw) ->
                       // This is an implied scalar register.  
                       // No other semantics can be assigned to any components
                       //   of this register.
                       // If pointsize declaration is not used (typical),
                       //   only 11 "out" registers are available, not 12.
                       // Pixel shaders cannot see this value.

최저한의 operating systemWindows 98


© 2002 Microsoft Corporation. All rights reserved.
↑TOP