Friday, January 27, 2012

So yeah...

I think, but I'm still not certain, that I will be changing my senior project from developing in WebOS to the Android platform. The entire reason really is C++ vs Java. Normally I'm a big C++ fan but when dealing with images and simple GUI's... Java wins...

So in some of my research I've been doing just to get a basic idea of what to do in java, I've actually made some progress in the QR code detection area.


Yes I am really that excited I drew colored lines on this picture... but more importantly, my program was able to find the finder patterns on the QR code (the boxes in the corners), even when it wasn't a square QR code.

//END OF LINE

Wednesday, January 25, 2012

Stuck

Well I got a GUI design for my QR code up and running... which is great but it really doesn't do much with the current stub code I have. But I've run into some problems. Obviously javascript isn't going to be able to do the image processing I would like it to do so I have to use something else. Luckily WebOS has a PDK for just that sort of thing. It allows the developer to "seamlessly" integrate c/c++ into their app. Well that's all fine and dandy if I had an actually c++ program up and running (which of course I don't). So I've been doing some research as to how I'm going to implement the actually pulling out of the QR code from an image and I honestly have no idea. I have to figure out how I'm going to actually pull the image into the program (because c++ has no built in libraries for doing that) and then implement an actually algorithm for finding and then decoding the QR code. I just haven't had the time I need/want to do more research.

The weekend is coming up soon and I have another project due soon but hopefully I'll be able to get some time to figure out where I'm headed.

//END OF LINE

Thursday, January 19, 2012

Finally Some Success!!!

After many long days and nights of searching, struggling and always coming up empty handed, I have finally figured out how to take pictures using enyo on a WebOS platform. It has been so frustrating because all the resources I have found are slightly vague and not very useful. Documentation for the framework is slightly lacking from what I've seen and it's been a real fight to find a solution. But as I said before I have finally found one. I'm planning on implementing it in with the rest of my UI design for my QR Reader and hopefully it will all work out smoothly... (that never happens...).

But for those you just as frustrated as I was, here's my .js file for my project so far.

enyo.kind
({
name: "MyApps.Capture",
kind: "VFlexBox",
components:
[
{kind: "Video", name: "streamTheVideo", style:"width:98%;height:93%;top:6%;left:1%;position:fixed"},
{kind: "enyo.MediaCapture", name: "mediaCaptureCamera", onInitialized: "loadCamera",
onImageCaptureComplete: "pictureTaken", onError: "someErrorOccured"},
{kind:"Button", name: "myButton", caption: "Take Picture", onclick:"capturePicture"}
],
load: function()
{
this.$.mediaCaptureCamera.initialize(this.$.streamTheVideo);
},

rendered: function()
{
this.inherited(arguments);
this.$.mediaCaptureCamera.initialize(this.$.streamTheVideo);
},

unload: function()
{
this.$.mediaCaptureCamera.unload();
},

loadCamera: function(inSender, inResponse)
{
var format;
for (i = 0; inResponse["video:1"].supportedImageFormats.length != i; ++i) {

fmt = inResponse["video:1"].supportedImageFormats[i];
if (fmt.mimetype == "image/jpeg") {
break;
}
}
this.$.mediaCaptureCamera.load(inResponse["video:1"].deviceUri, fmt);
},

pictureTaken: function(inSender)
{
this.captureType = "IMAGE";
this.$.myButton.caption = "picture Taken";
},

capturePicture: function()
{
var myexifdata  =  {
orientation: 3
};
var ImageCaptureOptions ={orientation: 3,'quality' : 100,'flash':"FLASH_AUTO",'reviewDuration':5,'exifData':myexifdata};
this.picName = "PicSample" + Date.parse(new Date()) ;
this.$.mediaCaptureCamera.startImageCapture('/media/internal/dts/image/' + this.picName + '.jpg', ImageCaptureOptions);
}
});


Some of the stuff I'm probably and hopefully end up changing when I implement it in my QR Reader, but for now it just works.

//END OF LINE

Friday, January 13, 2012

WebOSing

I've gotten to work in WebOS a little more and I've had some progress. I'm getting really excited to work on my senior project. It's going to be pretty awesome... hopefully.


This is how I'm feeling... which is what I've been wanting for a long time!

//END OF LINE

Tuesday, January 3, 2012

More Research

As I keep reading all these papers about QR codes and decoding them, I can't believe I didn't realize how complicated this project could end up being.

Because of the way QR Codes were designed it makes decoding them pretty quick and easy, but due to the nature of what devices are being used to "take the pictures", it presents quite a lot of problems. Direction, lighting, backgrounds, and skews can all be present and accounted for, this can make decoding more involved.

Luckily for me I shouldn't have to worry about most of these problems if I choose not to. Once I get the basics down, I may be able to add some of these features on to my project. But for now, I'm still stuck doing my research and starting soon on my actual requirements specification.

//END OF LINE

Monday, January 2, 2012

Research

This project is going to be the end of me. I'm only in the research phase right now, which has been interesting but slightly boring. I have been reading lots of papers and feeling like I'm getting nothing out of them, what I really want to do is to start the actual coding part of project and start seeing some results.

//END OF LINE