Example #1
0
ModelWorld* CreateModelWorld()
{
    ModelWorld* world = new ModelWorld;
    memset(world, 0, sizeof(ModelWorld));
    InitReferenceCounter(&world->refCounter);
    REPEAT(MAX_MODELS, i)
        world->drawEntries[i].generatedVariableSet = CreateShaderVariableSet();
    return world;
}
Example #2
0
LightWorld* CreateLightWorld( const char* lightCountUniformName,
                              const char* lightPositionName )
{
    LightWorld* world = new LightWorld;
    memset(world, 0, sizeof(LightWorld));
    InitReferenceCounter(&world->refCounter);
    CopyString(lightCountUniformName,
               world->lightCountUniformName,
               sizeof(world->lightCountUniformName));
    CopyString(lightPositionName,
               world->lightPositionName,
               sizeof(world->lightPositionName));
    world->shaderVariableSet = CreateShaderVariableSet();
    return world;
}
Example #3
0
void InitShader()
{
    GlobalShaderVariableSet = CreateShaderVariableSet();
}