Forum Discussion
Altera_Forum
Honored Contributor
16 years agoHow to import an image to Nios II as an array?
Hi,
Does anyone know how to convert any type of image into a c array which can be read by using the gimp bmp library in the Nios II IDE 9.0? Yours, Hany Assasa3 Replies
- Altera_Forum
Honored Contributor
Something like the following will generate a data item initialised with the bytes from a file - which might do what you want:
objcopy -I binary -O elf32-little -B nios2 --rename-section .data=.rodata,alloc,load,readonly,data,contents image.bmp image.o - Altera_Forum
Honored Contributor
Thanks for your reply dsl,
But can you give me an example about how to use this statment? - Altera_Forum
Honored Contributor
Hi,
Could u be able to load the image? Can you please share the code?