Here's what I want to do.
I'd like to create a new QR code reader, using Zxing.
What I downloaded.
Eclipse SDK Classic Version: 3.7.0; Android SDK (with SDK Tools rev12, and all SDK Platforms, API's, and samples; ADT Plugin in Eclipse (I can see all the API's targets on a list: 1.5-3.2 & Google API's); Zxing 1.7.
Using. Windows 7 32bits.
What are my environment variables.
ANT_HOME, at (...)\apache-ant-1.8.2
JAVA_HOME, at (...)\jdk1.7.0
PATH, at (...)\jdk1.7.0\bin
What I did.
Extracted Zxing 1.7 into a zxing folder, successfully built core.jar using cmd (typing "ant -f core/build.xml" at (...)\zxing; Created two android virtual machines using SDK Manager (Android 1.5 & Android 2.1); Set up SDK Location in Eclipse properties (C:\PROGRA~1\Android\android-sdk). (Sorry if I'm miss something) Created a new Android Project, selected "Create project from existing source", using folder (...)\zxing\android. And selected Android 2.1-update1 version.
In this project properties, I've added at "Java Build Path" -> "Libraries" -> Add External JARs" the file core.jar, at (...)\zxing\core.
Ultimately, I have the the following src:
`com.google.zxing.client.android
com.google.zxing.client.android.book
com.google.zxing.client.android.camera
com.google.zxing.client.android.encode
com.google.zxing.client.android.history
com.google.zxing.client.android.result
com.google.zxing.client.android.result.supplement
com.google.zxing.client.android.share
com.google.zxing.client.android.wifi`
Only *.android.camera seems to be fully working;
The AndroidManifest.xml has some errors though: at
`<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.google.zxing.client.android"
android:versionName="3.61 beta 1"
android:versionCode="71"
android:installLocation="auto">`
no resource identifier found for attribute 'installLocation' in package 'android'
and at
`<supports-screens android:xlargeScreens="true"
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true"
android:anyDensity="true"/>`
no resource identifier found for attribute 'xlargeScreen' in package 'android'
Therefore, I cannot build the project. What can I do? Seems like I've wrongly installed some of the components (possibily Android SDK). Any hints?
Need some help regarding other stuff.
Ummm, if I manage to compile the project, how can I call the scanner?
`Bitmap bMap = BitmapFactory.decodeStream(new FileInputStream(file));
LuminanceSource source = new RGBLuminanceSource(bMap);
BinaryBitmap bitmap = new BinaryBitmap(new HybridBinarizer(
source));
Reader reader = new MultiFormatReader();
Result result = reader.decode(bitmap);`
And how can I output the files? For instance, I'd like to process the information contained in the QR code. What are the other types of files that I can output the code?
How can I convert this into a library?
How can I import classes? Do I have to include them on AndroidManifest.xml?
Didn't understand this:
In your app's Eclipse build path add reference of zxing-core project so that it is not compiled by JVM.
I have found other method to output files through Intent. But I couldn't get it to work because I needed to download and install some files. What are they?