Go Back   Android Forums > Android Development > Application Development
Application Development Dev lounge for our application developers.

Get excited for the Samsung Galaxy S5! Find everything you need and discuss it in our Galaxy S5 Forum!

test: Reply
 
LinkBack Thread Tools
Old January 29th, 2013, 06:39 PM   #1 (permalink)
New Member
Thread Author (OP)
 
Join Date: Sep 2009
Posts: 4
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default opencv4android Hello OpenCV Sample - confused

Android development with OpenCV — OpenCV 2.4.3 documentation

Hi All,
I'm trying the tutorial located here. I have compiled sample code for openCV without issues - so I'm sure I have all the necessary things installed for opencv. I've added the opencv library to my project and I'm compiling with java 1.6 (java 7 doesn't work with opencv4android right now).

However, the sample code doesn't make sense to me once it gets to step 5 under Hello OpenCV example.
[HIGH]
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
mView = new HelloOpenCVView(this);
setContentView (mView);
}[/HIGH]

Is the code I'm talking about, I immediately get the error "mView cannot be resolved to a variable" which makes sense to me...
shouldn't it be...

[HIGH]
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
HelloOpenCVView mView = new HelloOpenCVView(this);
setContentView (mView);
}[/HIGH]

The only thing is mview is consistently used without declaration throughout the code, so I think I'm missing something major. Anyone know what is supposed to be going on here/why it isn't working? Thought that it would be relatively easy to run the hello OpenCV example...

benjamin.grant.du is offline  
Reply With Quote
sponsored links
Reply
Tags
opencv, opencv4android


Go Back   Android Forums > Android Development > Application Development
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 04:21 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.