image

How to convert BYTE* into a gdi+ image object?

I want to convert a BYTE* into an gdi+ Image object. How can I do this? The BYTE* seems a Dib point. I found Image has a method named Image::FromStream() which may help, But I can not find any reference about how to convert a BYTE* into a IStream object. How can I do this? Thanks in advance! Actually, it is hard to believe MS provide...

Slide show using Javascript

Hi, I have a slide show using javascript where images display from another server (remote server). i have to display images from another server,problem is when i set "src" property of "Img" html tag, it append my server localhost path at starting as "http:\mysitehost.com\myremoresite.com\image1.jpg" where my image path is "http:\myremote...

Replace Unavailable Images via CSS?

Is it possible to replace the standard broken image via CSS or using another technique? All my images are the same size and my have transparency. I've tried to wrap all images with a div's background: <div class="no_broken"> <img src="http://www.web.com/found.gif"/&gt; </div> <div class="no_broken"> <img src="http://www.web.com/no...

How can I determine if an image has loaded, using Javascript/jQuery?

I'm writing some Javascript to resize the large image to fit into the user's browser window. (I don't control the size of the source images unfortunately.) So something like this would be in the HTML: <img id="photo" src="a_really_big_file.jpg" alt="this is some alt text" title="this is some title text" /> Is there a ...

Packing rectangular image data into a square texture.

I have N items of 2D image data that will be rectangular and I want to pack them into a single power of 2 texture as efficiently as possible. A simple non-efficient and naive implementation of an algorithm to pack these rects would be easy to whip up, but I'm sure people have come up with algorithms to do this as space efficiently as po...

In java, how do you write a java.awt.image.BufferedImage to an 8-bit png file?

I am trying to write out a png file from a java.awt.image.BufferedImage. Everything works fine but the resulting png is a 32-bit file. Is there a way to make the png file be 8-bit? The image is grayscale, but I do need transparency as this is an overlay image. I am using java 6, and I would prefer to return an OutputStream so that I ...

Python: Check if uploaded file is jpg

How can I check if a file uploaded by a user is a real jpg file in Python (Google App Engine)? This is how far I got by now: Script receives image via HTML Form Post and is processed by the following code ... incomming_image = self.request.get("img") image = db.Blob(incomming_image) ... I found mimetypes.guess_type, but it does not ...

How to create a picture with animated aspects programmatically

Background I have been asked by a client to create a picture of the world which has animated arrows/rays that come from one part of the world to another. The rays will be randomized, will represent a transaction, will fade out after they happen and will increase in frequency as time goes on. The rays will start in one country's bou...

JPEG or other lossy image compression library needed

I've incorporated LIBPNG and ZLIB into my C software for a microcontroller project due to their nicely liberal license which permits such use without requiring me to disclose any of my code (it's very similar to BSD/MIT/APACHE, but with no attribution requirement). I'd like to look at using lossy image compression to save memory. The J...

Java in Eclipse: Where do I put the images (on the filesystem) that I want to load into an ImageIcon

I know the image file needs to be where the getClass().getResource(filename) can find it, but I don't know where that is. I'm interested both in where to put the images on the filesystem itself, and how to go about using Eclipse's functionality to set up the resources. ...

Where can I find Free Weather Icons?

Related to http://stackoverflow.com/questions/139944/where-can-one-find-free-software-icons-images I have a need for free icons relating to weather. Specifically, I need icons that you might see in a 10-day forecast (Clear Day/Night, Rainy Day/Night, etc.) Where could I find such images? Requirements: Like the linked question above, ...

GZipStream And DeflateStream will not decompress all bytes

I was in need of a way to compress images in .net so i looked into using the .net GZipStream class (or DeflateStream). However i found that decompression was not always successful, sometimes the images would decompress fine and other times i would get a GDI+ error that something is corrupted. After investigating the issue i found that t...

How to Convert DIB to BMP?

How to Convert DIB to BMP? ...

PHP Replace Images with GD Library Resampled Images in Joomla

I am the tech intern for an online independent newspaper, and the writers on the staff are not tech-savvy. They don't quite understand how web pages work, and often they upload and include images straight from their digital cameras, or scanned from original media. These images become a burden when there are 10 images on the front page ...

How do I resize an image using PIL and maintain its aspect ratio?

Is there an obvious way to do this that I'm missing? I'm just trying to make thumbnails. ...

Capturing image from webcam in java?

How can I continuously capture images from a webcam? I want to experiment with object recognition (by maybe using java media framework). I was thinking of creating two threads one thread: Node 1: capture live image Node 2: save image as "1.jpg" Node 3: wait 5 seconds Node 4: repeat... other thread: Node 1: wait until image is c...

Making an Image Greyscale with GD Library

My mission is to create a little app where you can upload a picture, and the app will turn it into ASCII art. I'm sure these exist already but I want to prove that I can do it myself. This would involve taking an image, making it greyscale and then matching each pixel with a character depending on how dark the picture is and how full th...

Visual Studio: How to store an image resource as an Embedded Resource?

By default when you add an image (icon, bitmap, etc) as a resource to your project, the image's Build Action is set to None. This is done because the image is magically stored inside a .resources file. I want the resource to be stored as an embedded resource (my reasons are irrelevant, but let's just pretend it's so that I can see them ...

Javascript callback for knowing when an image is loading

I want to know when an image has finished loading. Is there a way to do it with a callback? If not, is there a way to do it at all? ...

Tiff compression using Java ImageIO

I am having issues converting a png to tiff. The conversion goes fine, but the image is huge. I think the issue is that I am not doing the compression correctly? Anyone have any suggestions?? Here is the code sample public static void test() throws IOException { // String fileName = "4958813_1"; String fileName = "4848970_1"; St...