Ignore:
Timestamp:
07/07/08 10:52:03 (16 years ago)
Author:
mattausch
Message:

worked on deferred shading

File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Vis/FriendlyCulling/src/SceneEntity.cpp

    r2802 r2818  
    44#include "Material.h" 
    55#include "RenderState.h" 
     6#include <Cg/cg.h> 
     7#include <Cg/cgGL.h> 
    68 
    79 
     
    911{ 
    1012 
     13CGparameter SceneEntity::sModelMatrixParam; 
    1114 
    1215SceneEntity::SceneEntity(Geometry *geometry,  
     
    2932        if (mTransform) 
    3033        { 
    31                 glPushMatrix(); 
    32                 glMultMatrixf((float *)mTransform->x); 
     34                cgGLSetMatrixParameterfc(sModelMatrixParam, (const float *)mTransform->x); 
     35                //glPushMatrix(); 
     36                //glMultMatrixf((float *)mTransform->x); 
    3337                mGeometry->Render(state); 
    3438 
    35                 glPopMatrix(); 
     39                //glPopMatrix(); 
    3640        } 
    3741        else 
    3842        { 
     43                static Matrix4x4 identity = IdentityMatrix(); 
     44 
     45                cgGLSetMatrixParameterfc(sModelMatrixParam, (const float *)identity.x); 
    3946                mGeometry->Render(state); 
    4047        } 
Note: See TracChangeset for help on using the changeset viewer.