Images in bin/data not being copied over [SOLVED]

this is probably a horrible beginner question, but i’m not able to get the contents of bin/data copied to the device (kindle fire hdx). i’m using eclipse and of 0.8.4.

androidImageExample works fine, and the data folder has a little wrench on it. the example runs, and when i look at the filesystem of the device everything is there.

when i try to create my own bin/data folder and add an image it is not copied to the device. there is an error loading the file and when i look at the filesystem of the device nothing is there.

i’ve tried various combinations of creating the folder inside and outside eclipse, adding or importing through the eclipse IDE all to no avail.

is there some simple step i’m missing that is preventing me from having my images copied over? i’m at a point where i don’t know how to continue to debug this.


egad, it was a bad project rename. thought we had renamed everything, but the appname as defined in strings.xml is actually is what is used to unzip the bin/data onto the android sd card. oops!

it is true,you should see the makefile,everything is clear.and u can change the zip file name to anything you like.for me,i move zip to assets dir,and use my own way to unzip it.because the ofxandroid about this is so bad.

is this a way to avoid “eclipse deletes bin/data on clean” problem?

sure,but i modify the rule to zip data file into the assets dir not the raw clean is making no difference

I bumped into this exact problem a few days ago, and basically arrived at the same solution (the fact that the APPNAME is used to create the archive (and not the package name), as indicated by the makefile here.

I would also like to know how to stop Eclipse from clearing bin/data, as it would be nice to keep things consistent to how oF generally manages content. Any ideas?

This should work, thanks! But for the purpose of learning, could you tell us how we might get Eclipse to not clear bin/data on clean? Thanks agian.

in a style perhaps consistent to this thread, i will attempt to answer my own question :wink: -

looks like you can set it in the compiler settings (Eclipse->preferences->Java->compiler->Building: Output Folder) and deselect the “Scrub output folder on clean” option, as mentioned here.

This however is perhaps not in the spirit of things for Eclipse/java, so its more of an override to conform with oF’s bin/data structure for assets; so maybe tsin’s solution is better from the Eclipse/java context…

one thing i just noticed is that in the example projects there is a little “key” icon on the folder…

i think that means that they dragged the folder into the project and chose “link folder and files” so i’ve been doing the same and just re-dragging my data/ folder after every clean

you are right,but i don’t like use resource in the raw file,so,i change the source code,and use it in my own way.Everything is OK,and i think the has some errors.
hope you try my pure OF APP ----> Tipix

do you still do the unzip process? i have a 2GB and it takes forever to unzip it on device (i think)…

is it possible to just put a bunch of flat files in /res/raw and avoid that unzip step? is that sort of what you did?

but this is so big resoureces!?if needed,you may not package it into APK,you can do this when first start,download from network. Don’t do this in APK.

well, it’s a FMV game so we need everything. i’ve actually had timeout problems (haven’t solved yet with eclipse adb timeout settings) so we may need to use network after all. hopefully i can figure it out!

i think this can download from network,just when loading page!here not need everything just a download progressbar.may be,split the file,download the part when need.hope u lucky