image-processing

OpenCV: Fetch color, intensity and texture of an image

Hi I'm new to OpenCV and just started sifting through the APIs. I intend to fetch the color, intensity and texture values of each pixel constituting the image. I was fiddling with the structure - IplImage to start with but couldn't make much progress. Please let me know of any means to do this. cheers ...

Suggestions on generating abstract little images like StackOverflow 'flair' image

Hi All, I'm creating a webapp that has various unrelated data types (House, Contact, Article, Recipe, Fact -etc). I am giving each one a 'thumbnail' automaticaly. (User can then manually upload there own image). Currently, I'm grabbing an image from Flikr, crop or strech to 80x80 & adding a mosaic filter at 10 pixels. The result is a n...

draw semi-transparent line with ImageMagick

Hi, is it possible to draw a line semi-transparent with image magick? i want to draw a line and a semi-transparent just next to it to create a anti-alias effect (maybe that is a better description of my question :)) Michel ...

Cannot convert java.awt.image to int[][][]

I've written a class that I use for image processing in my Java program. The class cannot load an image properly, the 'data' field has the format [row][column][a=0,r=1,g=2,b=3]. When I try to load an image, the data is filled with 0s. public class Image { public int[][][] data; public int width; public int height; Image...

Fastest method to compute convolution

I have to apply a convolution filter on each row of many images. The classic is 360 images of 1024x1024 pixels. In my use case it is 720 images 560x600 pixels. The problem is that my code is much slower than what is advertised in articles. I have implemented the naive convolution, and it takes 2m 30s. I then switched to FFT using fft...

Nearest-neighbor interpolation algorithm in MATLAB

I am trying to write my own function for scaling up an input image by using the Nearest-neighbor interpolation algorithm. The bad part is I am able to see how it works but cannot find the algorithm itself. I will be grateful for any help. Here's what I tried for scaling up the input image by a factor of 2: function output = nearest(inp...

How to programmically get the height/width of an image?

On my PHP application, I allow users to upload images. I then process the images to resize it to a manageable size. Within my PHP script, I run the following UNIX command (ImageMagick): convert -size 320x240 This limits/constrains the height/width to be no larger than 320 by 240. However, I don't know actually what size "convert" r...

Can ImageMagick return the image size?

I'm using ImageMagick from the command line to resize images: convert -size 320x240 image.jpg However, I don't know what size ImageMagick is resizing the image too. Since this is a proportionaly image scale, it's very possible that new image is 100x240 ... or 320x90 in size (not 320x240). Can I call the 'convert' command to resize t...

comparing images programmatically - lib or class

My objective is to supply 2 image files, and get a true/false response as to whether these 2 files could be the same (within an acceptable degree of certainty). I realize this question falls under artificial intelligence and is much more complex than it appears, so I highly doubt I could (or would even want to) do it myself. What I'm l...

Scaling images stored at S3

I'm in a situation where I need to push image storage for a number of websites out to a service that can scale indefinitely (S3, CloudFiles, etc.). Up until this point we've been able to allow our users to generate custom thumbnail sizes on the fly using Python's Imaging library with some help from sorl-thumbnail in Django. By moving ou...

openCV combining an image to another image on given coordinates

hi i wrote a face & eye detection code next step is put an image to the coordinates of the detected eye (for ex: eye patch, eye glasses) i couldn't find the function to combine the source frame and the image I want to add any suggestions thanks ...

iText inserts JPG into created PDF in Windows but not Linux

When programmatically creating a PDF document using iText, I'm able to insert a JPG image into the document's header on my local environment (Windows XP). However, when executing the same code on our test environment (Linux based), iText throws an exception claiming the image file "is not a recognized imageformat", in com.lowagie.text.Im...

openCV: image on image

hi i want to paste an image to a captured video frame on the coordinates which i determined i asked that before and i have been told to use cvCopy and cvSetImageROI but i dont want to crop on those coordinates i want to add another image maybe its the right way but i didnt understand it (if its right pls explain it) thank for sugges...

Image resize with GDI in .NET gives low saturation

I'm fighting an issue where my resized images looses color saturation when I manipulate them using GDI. I'm loading an JPG as original, resize it and the resulting image has a lot less saturation (color intensity) than the original picture. What can I do to improve that? this is my code: using ( var original = System.Drawing.Image.F...

How can I extract objects from a bitmap image?

I have a bitmap with black background and some random objects in white. How can I identify these separate objects and extract them from the bitmap? ...

.Net - Argument Exception When Trying to Convert Bitmap to JPEG

So I was trying to convert a Bitmap image to JPEG in code and I keep getting this error: An unhandled exception of type 'System.ArgumentException' occurred in System.Drawing.dll Additional information: Parameter is not valid. Here is the related code. All the paths are correct and the EncoderParameter is not null, what ...

PHP: how do I convert a non-truecolor image to a truecolor image?

How to do that with GD? ...

High-speed performance of image filtering in C#

I have Bitmap. I want to apply median filter to my bitmap. But I can’t use GetPixel() and SetPixel() because speed is very important factor for me. I need very fast way to do it. May be it can be done with a Graphics.DrawImage(Image, Point[], Rectangle, GraphicsUnit, ImageAttributes). After median filter I want to apply binaryzation fil...

convert rgb 2 black & white in opencv

i need to know the function that convert RGB image into black &white(binary image) & i need to know if i can save modified image after conversion on hard disk if so what's this function? ...

How to identify black or dark images in C#?

Hi How to identify black/dark image in C#. Is there any API to check the image visibility or darkness ratio? In my application, while copying images, I want to check each image and want to discard black images. Any Idea how to achieve this? ...