本文整理汇总了C++中KX_LightObject::GetBlenderObject方法的典型用法代码示例。如果您正苦于以下问题:C++ KX_LightObject::GetBlenderObject方法的具体用法?C++ KX_LightObject::GetBlenderObject怎么用?C++ KX_LightObject::GetBlenderObject使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类KX_LightObject
的用法示例。
在下文中一共展示了KX_LightObject::GetBlenderObject方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GPU_lamp_from_blender
GPULamp *RAS_OpenGLLight::GetGPULamp()
{
KX_LightObject* kxlight = (KX_LightObject*)m_light;
if (m_glsl)
return GPU_lamp_from_blender(kxlight->GetScene()->GetBlenderScene(), kxlight->GetBlenderObject(), kxlight->GetBlenderGroupObject());
else
return NULL;
}
示例2:
RAS_OpenGLLight::~RAS_OpenGLLight()
{
GPULamp *lamp;
KX_LightObject *kxlight = (KX_LightObject *)m_light;
Lamp *la = (Lamp *)kxlight->GetBlenderObject()->data;
if ((lamp = GetGPULamp())) {
float obmat[4][4] = {{0}};
GPU_lamp_update(lamp, 0, 0, obmat);
GPU_lamp_update_distance(lamp, la->dist, la->att1, la->att2, la->coeff_const, la->coeff_lin, la->coeff_quad);
GPU_lamp_update_spot(lamp, la->spotsize, la->spotblend);
}
}
示例3: bounds
Image *RAS_OpenGLLight::GetTextureImage(short texslot)
{
KX_LightObject *kxlight = (KX_LightObject *)m_light;
Lamp *la = (Lamp *)kxlight->GetBlenderObject()->data;
if (texslot >= MAX_MTEX || texslot < 0) {
printf("KX_LightObject::GetTextureImage(): texslot exceeds slot bounds (0-%d)\n", MAX_MTEX - 1);
return NULL;
}
if (la->mtex[texslot])
return la->mtex[texslot]->tex->ima;
return NULL;
}