how to get FILE* from CPVRTResourceFile ?


I have a situation where I need to get the FILE* ptr which you obtain from fopen, but I need this from a the object of CPVRTResourceFile. How is this possible ?


hmm…ONLY source modification is the answer !! I actually needed this in Android, but I see you embed stuff into resource file and can be acccessed as string !! Suits me :slight_smile:

Request : please consider adding a function to retrieve FILE* ptr if not a memoryfile and where applicable. This is mainly to be compatible with other FILE handing sources.

CPVRTResourceFile, when using the default load function only has the file open temporarily while it reads everything into memory. Once it has done reading it closes the file so there would be no FILE pointer for you to retrieve if such a function existed.
From your own code you should be able to use fopen to get the FILE pointer that you can use.