temp
parent
578a7ac502
commit
f57e7221c0
|
@ -1,4 +1,4 @@
|
|||
/*
|
||||
/*
|
||||
Open Asset Import Library (assimp)
|
||||
----------------------------------------------------------------------
|
||||
|
||||
|
@ -115,7 +115,20 @@ glTF2Exporter::glTF2Exporter(const char* filename, IOSystem* pIOSystem, const ai
|
|||
ExportScene();
|
||||
|
||||
ExportAnimations();
|
||||
|
||||
|
||||
//wangyi 0608
|
||||
if(mProperties->HasPropertyCallback("extras"))
|
||||
{
|
||||
std::function<void*(void*)> ExportExtras = mProperties->GetPropertyCallback("extras");
|
||||
char* ret = (char*)ExportExtras((void*)mAsset.get());
|
||||
|
||||
Document extrasD;
|
||||
extrasD.Parse(ret);
|
||||
std::string strHello = extrasD["hello"].GetString();
|
||||
|
||||
printf("wangyi 0608 ret: %s\r\n", ret);
|
||||
}
|
||||
|
||||
AssetWriter writer(*mAsset);
|
||||
|
||||
if (isBinary) {
|
||||
|
|
|
@ -587,7 +587,7 @@ ExportProperties::ExportProperties(const ExportProperties &other)
|
|||
}
|
||||
|
||||
//wangyi 0608
|
||||
bool ExportProperties::SetPropertyCallback(const char *szName, std::function<void *(void *)> &f) {
|
||||
bool ExportProperties::SetPropertyCallback(const char *szName, const std::function<void *(void *)> &f) {
|
||||
return SetGenericProperty<std::function<void *(void *)>>(mCallbackProperties, szName, f);
|
||||
}
|
||||
std::function<void *(void *)> ExportProperties::GetPropertyCallback(const char *szName) const {
|
||||
|
|
|
@ -394,7 +394,7 @@ public:
|
|||
bool SetPropertyMatrix(const char *szName, const aiMatrix4x4 &sValue);
|
||||
|
||||
//wangyi 0608
|
||||
bool SetPropertyCallback(const char *szName, std::function<void *(void *)> &f);
|
||||
bool SetPropertyCallback(const char *szName, const std::function<void *(void *)> &f);
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
/** Get a configuration property.
|
||||
|
|
Loading…
Reference in New Issue