image

Creating huge images

My program has the feature to export a hi-res image of the working canvas to the disk. Users will frequently try to export images of about 20,000 x 10,000 pixels @ 32bpp which equals about 800MB. Add that to the serious memory consumption already going on in your average 3D CAD program and you'll pretty much guarantee an out-of-memory cr...

Using jQuery, how do you change the image on hover inside of a div?

I have the following jQuery code to replace an image when you hover over with the mouse but it doesn't seem to be working. What is wrong with the code below? $(function() { $("div.delete img") .mouseover(function() { $(this).attr("src", "../../images/comment-hover-del.png"); }) .mouseout(function() { $(this)...

How to find rectangle of difference between two images

I have two images the same size. What is the best way to find the rectangle in which they differ. Obviously I could go through the image 4 times in different directions, but i'm wondering if there's an easier way. Example: ...

Rails + Dragonfly gem: Saving image in a directory structure based on ActiveRecord object attributes

I'm using dragonfly gem to manage images and attachments in my rails app and I need to store images in a specific directory structure based on my user model. let' say I have user model which has a name and each user has many albums, which have a name also, then I want the images to be stored in "#{RAILS_ROOT}/public/system/#{user.name}/...

Addiing captions above images in wordpress

So I added some code in my css and there are boxes that appear over every image that is attached to a post. I've wanted to number the images and show the image number in the box(1...n). I have this in my functions.php edit: code was added here http://pastebin.com/gVszwf75 If I run only count_images it will show the correct number of at...

How do I make image hyperlinks have a background image?

I want all .jpg links to have a certain background image. so a link on a page like 'http://mysite/myimage.jpg' would automatically be prefixed with a small icon. Actually all links to images, ie .gif .png as well with the same icon. If the link is to a website, ie .htm/.php/.html/.asp it should have a different image. I want it to be thr...

Background image in java

hi, i'm trying to put an image as a background of my interface in java , i tried to write a class that does that and using it , but is there a simpler way to do that . here 's the code i used: import java.awt.BorderLayout; import java.awt.Dimension; import java.awt.GridBagConstraints; import java.awt.GridBagLayout; import javax.swing....

Displaying very large images on the iPad

I need to display some very large images on the iPad. The files are jpgs and are about 6700x2700 (maps). Is there any way around loading the entire image into memory? Currently I load it int a scroll view for zooming/panning. The images are stored locally on the device. ...

Java SWT - dissolve (fade) from one image to the next.

I'm pretty new to Java and SWT, hoping to have one image dissolve into the next. I have one image now in a Label (relevant code): Device dev = shell.getDisplay(); try { Image photo = new Image(dev, "photo.jpg"); } catch(Exception e) { } Label label = new Label(shell, SWT.IMAGE_JPEG); label.setImage(photo); Now I'd like photo to ...

How to converting BMP to AVI C#

I want to print screen 24 times in 1 second and then convert to AVI or VMW. İT's like video capture. is that possible ? ...

[Flash CS 4] - Batch export images from Library?

i have a flash .fla that was compiling as a .swc with references to images, but now I need to load all these images externally and I dont have the original assets. I know I can export them one by one, but I have a few hundred in the file, and want to find an easier way. Any help would be awesome. ...

How to make android app's background image repeat.

I have set a background image in my app, but the background image is small and I want it to be repeated and filled in the whole screen. What should I do <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:ba...

C# - Image as a clickable button

I want to make some custom controls, with images as buttons. I don't want images ON buttons - I want to totally replace the button with an image read from a file. Is it possible? ...

Single intent to let user take picture OR pick image from gallery in Android

I'm developing an app for Android 2.1 upwards. I want to enable my users to select a profile picture within my app (I'm not using the contacts framework). The ideal solution would be to fire an intent that enables the user to select an image from the gallery, but if an appropriate image is not available then use the camera to take a p...

Javascript Detect All Images (Including Asynchronous)

Is there a way in javascript to detect all images in a document, including those that may be loaded asynchronously (and maybe after the DOM is ready)? I'm looking to create a function that can detect if Google Analytics has been loaded by searching through the DOM looking for "__utm.gif". document.images doesn't seem to hold this image...

Image drawing library for Haskell?

I'm working on a Haskell program for playing spatial games: I have a graph of a bunch of "individuals" playing the Prisoner's Dilemma, but only with their immediate neighbors, and copying the strategies of the people who do best. I've reached a point where I need to draw an image of the world, and this is where I've hit problems. Two o...

XImage - how to resize?

I've got a XImage retrieved by XShmGetImage function. How can I resize it? Is there any function in X11 libraries to perform this operation or I need to use external library? ...

How can I create an image with Java?

I would like to create a gif image of a filled red circle on a green background. What is the easiest way to do it in Java? ...

Why I cannot see an image if I do not use the full name of an image?

I try to add an image to JPanel. It works if I specify the full name of the image (including name of all folders). But I want my software to be machine independent (another machine does not have the same folder structure as my machine has). So, I put my image to the same place where the source is and in my code I use just name of the ima...

Why I see only part of the image in the button?

I add an image to the button in the following way: ImageIcon icon = new ImageIcon("images/col.jpg"); tmp = new JButton(icon); My image is a red sphere but in my button I see only read color. I assume that I see just a small part of the sphere. How can I see the whole image in the button? ADDED Yes, my icon is bigger than the button....