[DEV] Invalid Output Mask?

Discussion in '3DS - Homebrew Development and Emulators' started by kprovost7314, Sep 28, 2016.

  1. kprovost7314
    OP

    kprovost7314 GBAtemp's Official Bara Master

    Member
    1,679
    865
    Dec 24, 2014
    United States
    In that bara manga ( ͡° ͜ʖ ͡°)
    Trying to make the 3DS Citro3D example "loop_subdivision" (the one with the OBJ file as coordinates), I get an error saying that "st" is an invalid output mask:

    and here's the code for the shader:

    Code:
    ; Example PICA200 vertex shader
    
    ; Uniforms
    .fvec projection[4], modelView[4]
    
    ; Constants
    .constf myconst(0.0, 1.0, -1.0, -0.5)
    .alias  zeros myconst.xxxx ; Vector full of zeros
    .alias  ones  myconst.yyyy ; Vector full of ones
    
    ; Outputs
    .out outpos position
    .out outtc0 texcoord0.st
    .out outval dummy.x
    
    ; Inputs (defined as aliases for convenience)
    .alias inpos v0
    .alias intc0 v1
    .alias inval v2
    
    .entry vmain
    .proc vmain
    	; Set the position (projection * modelView * inpos)
    	dp4 r15.x, modelView[0], inpos
    	dp4 r15.y, modelView[1], inpos
    	dp4 r15.z, modelView[2], inpos
    	dp4 r15.w, modelView[3], inpos
    	dp4 outpos.x, projection[0], r15
    	dp4 outpos.y, projection[1], r15
    	dp4 outpos.z, projection[2], r15
    	dp4 outpos.w, projection[3], r15
    
    	; Set the texcoord
    	mov outtc0.st, intc0
    	mov outtc0.pq, zeros
    
    	; Set the valence
    	mov outval, inval.x
    
    	; We're finished
    	end
    .end
    
    It won't compile since I have this error. Any way to fix it?
     
  2. Urbanshadow

    Urbanshadow GBAtemp Maniac

    Member
    1,289
    469
    Oct 16, 2015
    I doesn't like the line
    Code:
    .out outtc0 texcoord0.st
    as it reads the extension .st as an option for .out ( " " needed?)

    Check another examples of shaders for a proper definition of this file (if needed at all).
     
  3. einstein95

    einstein95 GBAtemp Regular

    Member
    228
    138
    Aug 31, 2013
    New Zealand
     
  4. kprovost7314
    OP

    kprovost7314 GBAtemp's Official Bara Master

    Member
    1,679
    865
    Dec 24, 2014
    United States
    In that bara manga ( ͡° ͜ʖ ͡°)
    How do I install the latest version (I have no idea how to use this TDM-GCC, I just installed it not knowing what to do)?