As long as you can avoid manipulating pixel values in Java (which will indeed be slow) you should be okay performance-wise... you may not need the NDK at all.
2,0,0,0,0, // R
0,2,0,0,0, // G
0,0,1,0,0, // B
0,0,0,1,0 // A
You may need to experiment a bit to get the effect you need.
HTH,
Reuben
On Mon, Mar 19, 2012 at 6:16 PM, Neil Glenister
<[address removed]> wrote:
Hi all,
I've been pulling my hair out over some problems with an image
processing app and wondered if any of you would be able to help/give
advice...
The app essentially takes the live camera feed and applies a simple
filter to it (e.g. yellow tint). The problem is that it runs far too
slow. The app MUST run without any lag at all for it to be usable.
I've been told that the only viable option is to use the NDK (based
on info from tight lipped companies who have achieved this) which I
have tried and so far I haven't managed to get it to work. What I'm
currently trying to do is push the two intensive parts through the
NDK:
1/ Converting the camera image format from YUV to RGB
2/ Applying the filters
The filters and YUV>RGB is readily available in Java so it's
"simply" a case of porting it to the NDK. I've tried
http://nhenze.net/?p=253 but it doesn't work and I can't get a hold
of the developer.
I guess my questions are:
a) Has anyone ever used the NDK with image processing?
b) Is there another way that's been tested and proven?
Thanks a lot in advance for any feedback!
Neil
-----------------------------------------------------
Neil Glenister
Technical Creative & MD
-----------------------------------------------------
Viral Media | Games | Apps | Interactive
118 Cavendish Road, London,
SW12 0DE
M:[masked] | T:[masked]
Follow us: @232studios
-----------------------------------------------------
--
Please Note: If you hit "REPLY", your message will be sent to everyone on this mailing list ([address removed])
This message was sent by Neil Glenister ([address removed]) from The London Android Group - Londroid.
To learn more about Neil Glenister, visit his/her member profile
Set my mailing list to email me As they are sent | In one daily email | Don't send me mailing list messages
Meetup, PO Box 4668 #37895 New York, New York[masked] | [address removed]