Changeset 92

Show
Ignore:
Timestamp:
02/26/05 12:28:44 (4 years ago)
Author:
aldacron
Message:

[DerelictGLU]
* coverted to using derelict.util.loader instead of std.loader. I overlooked it in the last commit

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/DerelictGLU/Makefile

    r74 r92  
    77DFLAGS = -v 
    88LIBFLAGS = -c -n        
    9 DINC = -I$(SRC.DIR) -I$(OGL.SRC.DIR) 
     9DINC = -I$(SRC.DIR) -I$(OGL.SRC.DIR) -I..\DerelictUtil 
    1010 
    1111GLU.SRC.DIR = $(SRC.DIR)\derelict\opengl 
  • trunk/DerelictGLU/derelict/opengl/glu.d

    r90 r92  
    3131 
    3232 
    33 private import derelict.opengl.gltypes; 
    34 private import std.loader; 
     33private 
     34
     35    import derelict.opengl.gltypes; 
     36    import derelict.util.loader; 
     37
    3538 
    3639version(Windows) 
     
    99102} 
    100103 
    101 private HXModule hglu; 
    102  
    103 private void* getProc(char[] procname) 
    104 
    105     void *symbol = ExeModule_GetSymbol(hglu, procname); 
    106     if(symbol is null) 
    107         throw new Exception("Failed to load glu proc address " ~ procname); 
    108     return symbol; 
     104private SharedLib libGLU; 
     105 
     106private void* getProc(char[] procName) 
     107
     108    return Derelict_GetProc(libGLU, procName); 
    109109} 
    110110 
    111111public void DerelictGLU_Load(char[] libName) 
    112112{ 
    113     if(hglu !== null) 
     113    if(libGLU !== null) 
    114114        return; 
    115115 
    116     hglu = ExeModule_Load(libName); 
    117  
    118     if(hglu is null) 
    119         throw new Exception("Failed to load the GLU shared library."); 
    120  
     116    libGLU = Derelict_LoadSharedLib(libName); 
    121117    load(); 
    122118} 
     
    132128public void DerelictGLU_Unload() 
    133129{ 
    134     if(hglu !== null) 
    135         ExeModule_Release(hglu); 
     130    Derelict_UnloadSharedLib(libGLU); 
    136131} 
    137132