added MaterialInstance::WriteMIData<>(const T &)
This commit is contained in:
parent
2f00aa8e1e
commit
12e18b517b
@ -69,7 +69,7 @@ private:
|
||||
|
||||
Color4f color=GetColor4f((COLOR)(i+int(COLOR::Blue)),1.0);
|
||||
|
||||
render_obj[i].mi->WriteMIData(color,sizeof(Color4f)); //设置MaterialInstance的数据
|
||||
render_obj[i].mi->WriteMIData(color); //设置MaterialInstance的数据
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -74,6 +74,9 @@ public:
|
||||
const int GetMIID ()const{return mi_id;} ///<取得材质实例ID
|
||||
void * GetMIData (){return material->GetMIData(mi_id);} ///<取得材质实例数据
|
||||
void WriteMIData (const void *data,const int size); ///<写入材质实例数据
|
||||
|
||||
template<typename T>
|
||||
void WriteMIData (const T &data){WriteMIData(&data,sizeof(T));} ///<写入材质实例数据
|
||||
|
||||
bool BindUBO(const DescriptorSetType &type,const AnsiString &name,DeviceBuffer *ubo,bool dynamic=false);
|
||||
bool BindSSBO(const DescriptorSetType &type,const AnsiString &name,DeviceBuffer *ubo,bool dynamic=false);
|
||||
|
Loading…
x
Reference in New Issue
Block a user