lucaseverini / simple-iphone-image-processing Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/simple-iphone-image-processing
Automatically exported from code.google.com/p/simple-iphone-image-processing
It would be good it the C++ code could all be moved behind the objective-C
wrapper. This would remove the need for having Objective-C++ in all the
project code.
Original issue reported on code.google.com by [email protected]
on 14 Mar 2009 at 12:44
NSPoint and NSRect are not available on the device.
I've temporarily typedeffed them to CGPoint and CGRect.
This should work on the device - we'll need to work out a way of switching
in the definitions for Simulator builds and unit test builds.
Original issue reported on code.google.com by [email protected]
on 15 Apr 2009 at 3:58
Use the Image::createImage(UIImage*,int width,int height) method to create a
new Image object
Notice that upon destruction of the object the m_imageData variable does not
get released
To fix this add:
m_ownsData=true;
To the bottom of the constructor mentioned at the top of this issue.
Original issue reported on code.google.com by [email protected]
on 29 Sep 2011 at 6:45
What steps will reproduce the problem?
1. Improve gaussianBlur() or take my improved code
2.
3.
What is the expected output? What do you see instead?
gaussianBlur() reduces image by 5 pixels in the upper left corner.
What version of the product are you using? On what operating system?
xCode and the newest version (13th july 2010)
Please provide any additional information below.
Fixed gaussianBlur() function:
ImageWrapper *Image::gaussianBlur() {
Image *result=new Image(m_width, m_height);
for(int y = 0; y < m_height; y++) {
for(int x = 0; x < m_width; x++) {
int val = (*this)[y][x]*41; //Declare currents pixels value
int middle = 41; //Declare average
if (x > 0) { val += (*this)[y][x-1] *26;middle += 26;}
if (x > 1) { val += (*this)[y][x-2] *7; middle += 7;}
if (x < m_width-1) { val += (*this)[y][x+1] *26;middle += 26;}
if (x < m_width-2) { val += (*this)[y][x+2] *7; middle += 7;}
if (y > 0) { val += (*this)[y-1][x] *26;middle += 26;}
if (y > 0 && x > 0) { val += (*this)[y-1][x-1] *16;middle += 16;}
if (y > 0 && x > 1) { val += (*this)[y-1][x-2] *4; middle += 4;}
if (y > 0 && x < m_width-1) { val += (*this)[y-1][x+1] *16;middle += 16;}
if (y > 0 && x < m_width-2) { val += (*this)[y-1][x+2] *4; middle += 4;}
if (y > 1) { val += (*this)[y-2][x] *7; middle += 7;}
if (y > 1 && x > 0) { val += (*this)[y-2][x-1] *4; middle += 4;}
if (y > 1 && x > 1) { val += (*this)[y-2][x-2] *1; middle += 1;}
if (y > 1 && x < m_width-1) { val += (*this)[y-2][x+1] *4; middle += 4;}
if (y > 1 && x < m_width-2) { val += (*this)[y-2][x+2] *1; middle += 1;}
if (y < m_height-1) { val += (*this)[y+1][x] *26;middle += 26;}
if (y < m_height-1 && x > 0) { val += (*this)[y+1][x-1] *16;middle += 16;}
if (y < m_height-1 && x > 1) { val += (*this)[y+1][x-2] *4; middle += 4;}
if (y < m_height-1 && x < m_width-1){ val += (*this)[y+1][x+1] *16;middle += 16;}
if (y < m_height-1 && x < m_width-2){ val += (*this)[y+1][x+2] *4; middle += 4;}
if (y < m_height-2) { val += (*this)[y+2][x] *7; middle += 7;}
if (y < m_height-2 && x > 0) { val += (*this)[y+2][x-1] *4; middle += 4;}
if (y < m_height-2 && x > 1) { val += (*this)[y+2][x-2] *1; middle += 1;}
if (y < m_height-2 && x < m_width-1){ val += (*this)[y+2][x+1] *4; middle += 4;}
if (y < m_height-2 && x < m_width-2){ val += (*this)[y+2][x+2] *1; middle += 1;}
(*result)[y][x] = (int)val/middle; //Calculating average value for given pixel
}
}
return [ImageWrapper imageWithCPPImage:result]; //Return the image
}
Original issue reported on code.google.com by [email protected]
on 13 Jul 2010 at 7:10
What steps will reproduce the problem?
1. invoke getPercentSet, linking fails
What is the expected output? What do you see instead?
I'm expecting all of the functions in Image.h to be implemented in Image.mm
What version of the product are you using? On what operating system?
svn revision 16
Please provide any additional information below.
I'm completely new to C/Obj-C/XCode/iPhone, so this may be my issue. I see
there are a handful of functions not implemented in Image.mm including
getPercentSet.
Original issue reported on code.google.com by [email protected]
on 13 Jul 2010 at 11:22
sorry to be dense, but how do I do that?
Original issue reported on code.google.com by [email protected]
on 9 May 2011 at 11:45
Hi Im new to image processing.
I would like to know if it is possible to modify the existing code to calculate
the edge gradient and direction and then shade the edges appropriately.
The attached file show an example of what Im looking to achieve.
Original issue reported on code.google.com by [email protected]
on 17 May 2011 at 6:38
Attachments:
What steps will reproduce the problem?
1.
2.
3.
What is the expected output? What do you see instead?
Please use labels and text to provide additional information.
Original issue reported on code.google.com by [email protected]
on 27 May 2009 at 5:54
The current way that bytes are converted back into an image could be improved.
Original issue reported on code.google.com by [email protected]
on 19 Mar 2009 at 10:44
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.