Pixel Manipulation In Corona

And just so Jeff doesn’t get the wrong idea, Corona Enterprise is NOT a magic wand for your problem. My understanding is that if you can’t code a getPixel(x,y) in Objective-C, then you can’t do it in Enterprise – because that’s how extra functionality is added there. Native coding, not easy-peasy Lua.

Jay

[import]uid: 9440 topic_id: 20559 reply_id: 138673[/import]

Yes, Jay is correct. You do need to do native coding with Corona Enterprise.

Also, I want to make something clear (lest some people get the wrong idea): I’m not saying we won’t add basic features to Corona SDK and we are therefore forcing people to pony up for Corona Enterprise. That is not our intention. However, the reality is that if you need something that is not in Corona SDK *now*, then that is one way to go. We are still *100%* focused on improving the core engine (core engine is the same in SDK and Enterprise).
[import]uid: 10668 topic_id: 20559 reply_id: 138675[/import]

If you want low level control you can’t use the display.* API since (as mentioned above) it’s not designed for it.
What you’ll need to do is to code your own image library API in Objective-C/Java, put a Lua wrapper around it and then link it to Corona.

What you’ll end up with is a library completely separate from any other Corona API, but it’ll do what you want it to. [import]uid: 70847 topic_id: 20559 reply_id: 138678[/import]

Me again.
I had intended to say my toddle-pips and come back in 6 months to see if anything happened, but of course I receive notifications of responses to the topic, and they have been interesting.

>>For iOS: If you can do it with Objective-C and iOS SDK, it can be done in Enterprise.<<
http://developer.apple.com/library/mac/#qa/qa1509/_index.html

If I have to do it in Objective C, I may as well knuckle down and learn enough to do the whole project in Obj-C
It’s a possibility, but I’m weighing up alternatives to Corona.
I’m pretty sure that I have to write it all again from scratch now.

>>The idea of paying $3,000 for me to load the same image twice, once via the display.API and again via my own lib just to see what the corresponding pixel is at (X,Y) seems a bit out of place here.<<
+1

[import]uid: 108660 topic_id: 20559 reply_id: 138681[/import]

Just so no one gets the wrong idea, enterprise does not cost $3,000. I’m an enterprise user and i can’t remember the exact price now, but it was no way near that.

Either way it would be a lot to pay just for that one feature, but if you do manage to get that working in enterprise you would be able to add many other libraries as well as having the speed of use of Lua. Coding a whole project in Obj-C really doesn’t sound so nice to me :slight_smile: [import]uid: 69826 topic_id: 20559 reply_id: 138683[/import]

jeff472 - As TandG says, Corona Enterprise does not cost $3000. That is an old number that got thrown around before we launched and had set pricing.

We are not trying to “hide” prices somehow. Here are the prices:

  1. If you are an indie/small company, it is $999/developer/year
  2. If you are a larger company, it is $2499/developer/year. This level also adds some workflow tools that are coming soon.

So, again, if you are interested feel free to send me an email (davidATcoronalabs). I can set you up with the 30 day trial.

Thanks,

David [import]uid: 10668 topic_id: 20559 reply_id: 138716[/import]

i think bitmap manipulation is an important feature missing from the Corona SDK

it’s been almost 2 years now since this feature has been requested by developers. the answer we’ve always got was “it’s on our feature pool”, “we’re considering it”, etc

Eric has pointed out (http://developer.coronalabs.com/forum/2010/05/01/image-manipulation) that it will kill performance. If bitmap manipulation is not compatible with the SDK, Corona Labs should clearly say so and not let the developers hope that one day they will be able to manipulate bitmaps with Corona. [import]uid: 6459 topic_id: 20559 reply_id: 138799[/import]

There are multiple different definitions of what bitmap manipulation means.

It would help us a lot — and more importantly help us understand what you’re trying to do — if you give us some sense of what use case you’re after:

(A) Read r,g,b,a value at x,y (i.e. the original thread question)
(B) Run a filter (e.g. sepia, contrast, etc) on the entire image
© Apply a color transform on the entire image (i.e. tinting + offset)
(D) Render display object to texture
(E) Other use case?

[import]uid: 26 topic_id: 20559 reply_id: 138857[/import]

walter, thank you for taking the time to address this
and ask what is it that we need

this is a list of things that i’d like to see supported by Corona

to get and set pixel rgb’s
to copy and set rectangles of pixels
to copy channels
to apply color and geometric (scale, rotate, skew) transforms
to adjust brightness, contrast, saturation
to set filters on a display object (shadow, blur, glow, sharpen)
to flood fill an image
to rotate an image around the axes (perspective)
to create noise
to dispose
[import]uid: 6459 topic_id: 20559 reply_id: 139090[/import]

Thanks tetu, this is helpful as we prioritize what we work on first in the next-gen graphics engine. [import]uid: 26 topic_id: 20559 reply_id: 139091[/import]