Changeset 304 for trunk/thune/gl
- Timestamp:
- 10/30/06 03:10:11 (2 years ago)
- Location:
- trunk/thune/gl
- Files:
-
- 4 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/thune/gl/gx.c
r303 r304 1851 1851 FIXED_ATOM( "vertex", 6, UR_ATOM_VERTEX ); 1852 1852 FIXED_ATOM( "fragment", 8, UR_ATOM_FRAGMENT ); 1853 FIXED_ATOM( "default", 7, UR_ATOM_DEFAULT ); 1853 1854 1854 1855 #if MAKE_ATOM_HEADER -
trunk/thune/gl/gx_atoms.h
r303 r304 21 21 #define UR_ATOM_VERTEX 319 22 22 #define UR_ATOM_FRAGMENT 320 23 #define UR_ATOM_DEFAULT 321 -
trunk/thune/gl/gx_dt.c
r301 r304 21 21 #include "os.h" 22 22 #include "gx.h" 23 #include "internal.h" 23 24 #include "urlan_atoms.h" 24 25 #include "gx_atoms.h" … … 314 315 UCell* res = ur_s_prev(tos); 315 316 UAtom cmd = 0; 317 UIndex defN = 0; 316 318 const char* vprog = 0; 317 319 const char* fprog = 0; … … 338 340 fprog = ur_cstring( it ); 339 341 break; 342 343 case UT_BLOCK: 344 if( cmd == UR_ATOM_DEFAULT ) 345 defN = it->series.n; 346 break; 340 347 } 341 348 ++it; … … 346 353 if( ! makeShader( ur_thread, res, vprog, fprog ) ) 347 354 return; 355 356 if( ur_is(res, UT_CONTEXT) && defN ) 357 { 358 ur_bind( defN, res ); 359 360 ur_initType( tos, UT_BLOCK ); 361 ur_setSeries( tos, defN, 0 ); 362 363 UR_CALL_OP = OP_DO; 364 return; 365 } 348 366 } 349 367 else -
trunk/thune/gl/test.t
r303 r304 50 50 ;"data/shader/testA.gx" 51 51 load.shader :test-shader 52 53 test-shader context! is-type? ift (54 1.0, 0.3, 0.2 :test-shader/brickcolor55 0.9, 0.85 :test-shader/brickpct56 1.0, 0.5 :test-shader/bricksize57 0.8, 0.8, 0.8 :test-shader/mortarcolor58 )59 ;test-shader .60 52 61 53 0,0,0 :strobe
