Blender V2.61 - r43446
|
#include <BL_BlenderShader.h>
Public Member Functions | |
BL_BlenderShader (KX_Scene *scene, struct Material *ma, int lightlayer) | |
virtual | ~BL_BlenderShader () |
bool | Ok () |
void | SetProg (bool enable, double time=0.0) |
int | GetAttribNum () |
void | SetAttribs (class RAS_IRasterizer *ras, const BL_Material *mat) |
void | Update (const class RAS_MeshSlot &ms, class RAS_IRasterizer *rasty) |
void | ReloadMaterial () |
int | GetAlphaBlend () |
void | SetScene (KX_Scene *scene) |
bool | Equals (BL_BlenderShader *blshader) |
BL_BlenderShader Blender GPU shader material
Definition at line 57 of file BL_BlenderShader.h.
Definition at line 23 of file BL_BlenderShader.cpp.
References KX_Scene::GetBlenderScene(), GPU_BLEND_SOLID, and ReloadMaterial().
BL_BlenderShader::~BL_BlenderShader | ( | ) | [virtual] |
Definition at line 36 of file BL_BlenderShader.cpp.
References GPU_material_unbind().
bool BL_BlenderShader::Equals | ( | BL_BlenderShader * | blshader | ) |
Definition at line 161 of file BL_BlenderShader.cpp.
int BL_BlenderShader::GetAlphaBlend | ( | ) |
Definition at line 156 of file BL_BlenderShader.cpp.
Referenced by KX_BlenderMaterial::ActivateMeshSlot().
int BL_BlenderShader::GetAttribNum | ( | ) |
Definition at line 57 of file BL_BlenderShader.cpp.
References BL_MAX_ATTRIB, GPUVertexAttribs::glindex, GPU_material_vertex_attributes(), i, GPUVertexAttribs::layer, and GPUVertexAttribs::totlayer.
Referenced by SetAttribs().
bool BL_BlenderShader::Ok | ( | ) | [inline] |
Definition at line 76 of file BL_BlenderShader.h.
References NULL.
Referenced by KX_BlenderMaterial::Activate().
void BL_BlenderShader::ReloadMaterial | ( | ) |
Definition at line 42 of file BL_BlenderShader.cpp.
References GPU_material_from_blender(), and NULL.
Referenced by BL_BlenderShader(), and SetScene().
void BL_BlenderShader::SetAttribs | ( | class RAS_IRasterizer * | ras, |
const BL_Material * | mat | ||
) |
Definition at line 77 of file BL_BlenderShader.cpp.
References CD_MCOL, CD_MTFACE, CD_NORMAL, CD_ORCO, CD_TANGENT, GetAttribNum(), RAS_IRasterizer::GetDrawingMode(), GPUVertexAttribs::glindex, GPU_material_vertex_attributes(), i, STR_String::IsEmpty(), RAS_IRasterizer::KX_TEXTURED, GPUVertexAttribs::layer, GPUVertexAttribs::name, RAS_IRasterizer::RAS_TEXCO_DISABLE, RAS_IRasterizer::RAS_TEXCO_NORM, RAS_IRasterizer::RAS_TEXCO_ORCO, RAS_IRasterizer::RAS_TEXCO_UV1, RAS_IRasterizer::RAS_TEXCO_UV2, RAS_IRasterizer::RAS_TEXCO_VCOL, RAS_IRasterizer::RAS_TEXTANGENT, STR_String::ReadPtr(), RAS_IRasterizer::SetAttrib(), RAS_IRasterizer::SetAttribNum(), RAS_IRasterizer::SetTexCoordNum(), GPUVertexAttribs::totlayer, GPUVertexAttribs::type, BL_Material::uv2Name, and BL_Material::uvName.
Referenced by KX_BlenderMaterial::ActivateBlenderShaders().
void BL_BlenderShader::SetProg | ( | bool | enable, |
double | time = 0.0 |
||
) |
Definition at line 47 of file BL_BlenderShader.cpp.
References GPU_material_bind(), GPU_material_unbind(), and Scene::lay.
Referenced by KX_BlenderMaterial::ActivateMat(), KX_BlenderMaterial::ActivatShaders(), and KX_BlenderMaterial::EndFrame().
void BL_BlenderShader::SetScene | ( | KX_Scene * | scene | ) | [inline] |
Definition at line 89 of file BL_BlenderShader.h.
References KX_Scene::GetBlenderScene(), and ReloadMaterial().
Referenced by KX_BlenderMaterial::Replace_IScene().
void BL_BlenderShader::Update | ( | const class RAS_MeshSlot & | ms, |
class RAS_IRasterizer * | rasty | ||
) |
Referenced by KX_BlenderMaterial::ActivateMeshSlot().