image-manipulation

programmatically trimming (automatically cropping out transparent boundaries) an image in objective-c / cocoa

Does anyone know how to trim an image (uiimage or cgimage). By trim I mean programatically cropping to the non-transparent bounds of an image. So if I have the image below: 00111000 00010000 01011110 00000000 it would yield: 011100 001000 101111 ...

Respecting EXIF orientation when displaying iPhone photos on the web

I am developing an iPhone camera app that uploads an image to Amazon S3 and that image is displayed on a website. When the iPhone takes a picture, it always saves the photo in an upright orientation, while the orientation used to correctly view the photo is saved in the image's EXIF data. So if I take a photo with the iPhone and open i...

Numpy image - rotate matrix 270 degrees...

I've got a Numpy 2d array that represents a grey-scale image and I need to rotate it 270 degrees. Might be being a bit thick here but the two ways I can find to do this seem quite... circulous: rotated = numpy.rot90(numpy.rot90(numpy.rot90(orignumpyarray))) rotated = numpy.fliplr(numpy.flipud(numpy.rot90(orignumpyarray))) I'm thinki...

Online Image editing Lib (like fotoflexer but open installable on my servers)

I would like to let my users edit their uploaded photos, e.g. with a flash interface like fotoflex.com at myspace (cropping, rotation, frames and whatnot) Are there any libs or flash programs you can recommend? Thx in advance ...

Scaling larger Image problem.

Hi, I m developing flex application, in which I want to Draw Image from User local hard-drive to the canvas of size 640x360. User can choose Image of bigger resolution & is scaled to Canvas size. But if user selected images of larger resolution like 3000x2000, the scaling take lot time & freezes the application until scale done. Is t...

Storing and Retrieving Images from Database using Python

Hi, I want to store the images related to a each person's profile in the DB and retrieve them when requested and save it as .jpg file - and display it to the users. How could I render the image data stored in the DB as an image and store it locally?? ...

Image anotation (Highlighting parts of an image, Scrubbing an image) using Javascript

Hi, We are working on an application and would like users to annotate an image. By annotation I mean, the ability to highlight parts of an image. Once the image is highlighted, and submit is clicked, the highlighted attributes (color, area highlighted) are submitted to the server to be stored in database. Is this possible using javascr...

rotate image with php - any degree

How to rotate an image with PHP, any degree, without having the filled space? For instance, if I rotate an image 10 degrees, the image rotates fine but the container around (square) gets filled with black. Is it possible to get rid of this, when for example merging 2 images? ...

How can I duplicate the UI functionality of Google Fastflip?

Trying to get the same functionality as Google FastFlip. Not just with the thumbnails, but even for the larger images too. Notice how when you click on a story, you see the main story front and center, and you see smaller half-screens of previous and next stories. How can I get that functionality? Is there a plugin for one of the JS fr...

How to scale up an image with PHP GD?

Hello, how can I do this? I have an image 50x50 and I would like to generate one with 100x100, where the original 50x50 will be centered inside of that one. The rest would be filled with "transparent". Thanks ...

Fast Perspective transform in Java Advanced Imaging API

For the needs of my program I have created a facility to distort an image and place it on a map (my program is a map based program). I wrote my own mechanism for placing and distorting the image using three points that are placed on the image, three points that are placed on the map and then what I simply do it create an AffineTransfor...

How to find about structure of bitmap and JPEG files?

I'm trying to write a very simple image processing program for fun and practice. I was using System.Drawing. ... .Bitmap class to handle images and edit their data. but now I want to write my own class of Bitmap object implementation and want to know how bmp files (and other common bitmap formats) and their meta-data (indexing, color sys...

How to select an image in FCKEditor 2.x using javascript

Hi all, Is there any way to select the image in FCKEditor 2.x using javascript api? I need select the first image automatically after the editor got focused. The the result should be the same as the user clicked on the image. Thank you in advance. ...

How to scale an image (in data URI format) in JavaScript (real scaling, not using styling)

We are capturing a visible tab in a Chrome browser (by using the extensions API chrome.tabs.captureVisibleTab) and receiving a snapshot in the data URI scheme (Base64 encoded string). Is there a JavaScript library that can be used to scale down an image to a certain size? Currently we are styling it via CSS, but have to pay performance...

How to access pixels of an NSBitmapImageRep?

I have an NSBitmapImageRep that is created like this: NSBitmapImageRep *imageRep = [[NSBitmapImageRep alloc] initWithBitmapDataPlanes:NULL pixelsWide:waveformSize.width pixelsHigh:waveformSize.height ...

Image cropping in PHP is producing blank result

I'm simply trying to crop a JPEG image (no scaling) using PHP. Here is my function, along with the inputs. function cropPicture($imageLoc, $width, $height, $x1, $y1) { $newImage = imagecreatetruecolor($width, $height); $source = imagecreatefromjpeg($imageLoc); imagecopyresampled($newImage,$source,0,0,$x1,$y1,$width,$height,...

How to work with images(png's) of size 2-4Mb.

I am working with images of size 2 to 4MB. I am working with images of resolution 1200x1600 by performing scaling, translation and rotation operations. I want to add another image on that and save it to photo album. My app is crashing after i successfully edit one image and save to photos. Its happening because of images size i think. I ...

Handling inverted pixels in bitmapData and bitmap class in as3

I am using bitmapData and bitmap classes to render a mouse cursor on the display screen. The bitmapData consists of an area whose colors should be inverted according to the background color. This is a very basic thing which could be observed with text cursor(the vertical line with two small horizontals on top and bottom), when moved over...

get average color of image via javascript

Not sure this is possible, but Looking to write a script that would return the average hex or rgb value for an image. I know it can be done in AS but looking to do it in JavaScript. ...

How to measure the pixel width of the string drawed over Drawing.Bitmap in .NET?

I am generating a png image that contains a text dinamically written. I need to create the bitmap with the minimum width for file size reasons. ...