I found a solution. My project folder is something like this:
project
|_ src
|_ examples
|_ example1
|_ main.c
|_ assets
|_ file.bmp
I was trying to get the file descriptor from the main.c
. The filePath would be assets/file.bmp
, but this isn´t true; I can get the file descriptor with the path from project folder, and the relative file path is examples/example1/assets/file.bmp
.