I push on git:
- CFileSystem.cpp to handle file
- An Utils class to put files from assets to /sdcard (like slytron)
With theses fixes, you can try particules engine, load 3ds files, load .irr scene and more
Have fun

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> boolean VxCreateDirectory( String strDirPath ) throws IOException
{
boolean bDirCreated = false;
File testDir = new File(strDirPath);
bDirCreated = testDir.mkdirs();
if( false == bDirCreated)
{
//Log.i(LOG_TAG, "ERROR: Create Directory failed " + strDirPath);
}
return bDirCreated;
}
// add earth sphere
log_msg( 0, "getting earth mesh\n");
irr::scene::IAnimatedMesh* poEarthMesh = m_poSceneMgr->getMesh("/sdcard/dtw/sphere.x");
if (poEarthMesh )
{
log_msg( 0, "creating earth\n");
irr::scene::ISceneNode* poEarthNode = m_poSceneMgr->addMeshSceneNode( poEarthMesh );
if( NULL == poEarthNode)
{
log_msg( 0, "Failed getting earth node");
}
irr::video::ITexture* poTexture = m_poDriver->getTexture("/sdcard/dtw/earth.jpg");
if( NULL == poTexture)
{
log_msg( 0, "Failed getting earth texture");
}
poEarthNode->setMaterialTexture(0, poTexture);
poEarthNode->setMaterialFlag(irr::video::EMF_LIGHTING, false);
//m_poEarthNode->setRotation( irr::core::vector3df(0.0f, 30.0f, 0.0f) );
irr::scene::ISceneNodeAnimator* anim = m_poSceneMgr->createRotationAnimator(irr::core::vector3df(0,0.3f,0));
poEarthNode->addAnimator(anim);
anim->drop();
}
Return to Project Announcements
Users browsing this forum: No registered users and 1 guest