Entries from 2011-10-01 to 1 month

how to import existing files as an Eclipse project

1)make sure no project is selected2)file->import->Existing Projects into Work Space3)select root directry4)check "Copy projects into workspace" (*IMPORTANT this may overwrite existing project)5)refresh 6)finish

fseek doesn't look working

void myLoadAsset(AAssetManager* mngr){ const char imageFilename[] = "myImage.png"; AAsset* asset = AAssetManager_open(mngr, imageFilename, AASSET_MODE_UNKNOWN); FILE* fp = (FILE*)AAsset_getBuffer(asset); // AAsset_seek(asset, 1000, SEEK_SE…

asset manager const void* AAsset_getBuffer(AAsset* asset);

const void* AAsset_getBuffer(AAsset* asset);Dianne Hackborn says: I suggest not using getBuffer() for a compressed file. It really only make sense for a file that isn't compressed, where this can give you a direct pointer to the mmapped da…

object types in ndk assetmanager

getBuffer returns the pointer to the mmapped image of the asset. openFileDescriptor returns the file descriptor to the mmapped image of the asset. fdopen(file descriptor) returns the pointer to the WHOLE package(.apk).