image

Uploadify with ruby on rails 'bad content body' 500 Internal Server Error

I'm Getting this error in my development log while uploadify is uploading the file and in the view i get an 'IO ERROR' beside filename. /!\ FAILSAFE /!\ Thu Mar 18 11:54:53 -0500 2010 Status: 500 Internal Server Error bad content body /usr/lib/ruby/gems/1.8/gems/rack-1.0.1/lib/rack/utils.rb:351:in `parse_multipart' /usr/li...

How do I track images embedded in HTML?

Hi, I'd like to track the views/impressions of images on web pages, but still allow the images to be embedded in HTML, like in the "img src="http://mysite.com/upload/myimage.jpg"/" element. I know in Windows I can write a handler for ".jpg" so the URL will actually trigger a handling function instead of loading the images from disk. Is...

Producing a color map image using Python

I have a working program in C++ that generates data for a Mandelbrot Set. I am able to get the color map image of the Mandelbrot set using gnuplot. In order to save the image, I just take a screenshot which doesn't give a very accurate image. how I can use a Python script in order to produce and save the image. ...

Cannot open a .tif with color using .Net Image or Bitmap classes

I am attempting to open .tif files that have color in them (300 dpi, PixelFormat.Format24bppRgb) using the .Net Image and Bitmap classes. I always get an "invalid parameter" error when the tiffs have color (works fine for black and white tiffs). If anyone has source code on how to open a .tif with color in it I'd deeply appreciate it. ...

How to find one image inside of another?

I have 2 bmp images. ImageA is a screenshot (example) ImageB is a subset of that. Say for example, an icon. I want to find the X,Y coordinates of ImageB within ImageA (if it exists). Any idea how I would do that? ...

Resizing Images with ASP.NET and saving to Database

I need to take an uploaded image, resize it, and save it to the database. Simple enough, except I don't have access to save any temp files to the server. I'm taking the image, resizing it as a Bitmap, and need to save it to a database field as the original image type (JPG for example). How can I get the FileBytes() like this, so I can...

Images saved with D3DXSaveSurfaceToFile will open in Paint, not Photoshop

I'm using D3DXSaveSurfaceToFile to save windowed Direct3D 9 surfaces to PNG, BMP and JPG files. There are no errors returned from the D3DXSaveSurfaceToFile call and all files open fine in Windows Photo Viewer and Paint. But they will not open in a higher end image editing program such as Paint Shop Pro or Photoshop. The error messages...

even PHP has 'bugs' with IE

This is not a real bug BUT for sure it is not what you would expect. I have this sample code to upload images: if($type=="image/jpg" || $type=="image/jpeg" || $type=="image/pjpeg" || $type=="image/tiff" || $type=="image/gif" || $type=="image/png") { // make upload else echo "Incorrect format ...."; The problem is that if I modify...

on hover overlay image in CSS

I need a div with picture bg to overlay an image (with some amount transparency) when hovered on. I need to be able to have one transparent overlay that can be used and reused throughout the site on any image. My first attempt was round-about to say the least. Because I found out you cannot roll-over an invisible div I devised a sandwhic...

Using hover to swap images, I don't want to swap images if I'm on '.this_page'...

When I land on the page, another function (not shown, that works fine) sets the class of the appropriate nav to '.this_page' and then I roll over, and the images swap correctly, but when I hover and leave 'img.this_page' it swaps, the second time I do the hover. I don't want it 'img.this_page' to swap. I tried unbinding mouseout, but on ...

Resizing gif images

I have a gif image 720 * 40 pixels used as a footer on a website. I need to extend the height of the gif by 10 pixels. I was unable to resize to this, using Office Picture Manager. What is the best way to achieve this? ...

What would cause all the images to your site not to show?

I've been working on a site for a client, and I'm taking a recently changed design and incorporating that design into the existing site. I was flipping back and forth between the two sites using firebug to compare the layout of the two. Everything was showing up fine, and I didn't have any problems. I stepped away from my computer for...

Fastest image drawing method on iPhone

I am trying to draw images to the iphone screen by changing the images of a UIImageView in a loop. But since there was no much response on the screen than two or three images being drawn and skipping others I need another method. I am trying to show 80 png images that are 320*480 in size at 30 images per second. Please suggest the fast...

Is PNG the most economically sound file format to store pictures in?

I am looking for an economically sound solution to store pictures long time. I read about the PNG file format that it has superior characteristics compared to JPEG, namely in these categories: no patents, no licenses, no royalities no quality loss yet compressed I have a lot of big ESP's from PhotoShop that contain tons of metadata,...

Center an Image vertically and horizontally? css

How do i vertically and horizontally center an image when i do not know the size of it? I asked this question and someone suggested using a table. This isnt the first time i heard a table can do it but i tried without luck. Searching SO only got me results when i do know the size of the image. How do i do this with a table? NOTE: Javas...

When creating an bitmap image from scratch in VB.Net, the quality stinks?

The Vb.Net application creates a bitmap from scratch and either converts to a tiff or sends it to a printer. In both cases, the quality of the image (in this case the font) is not good at all. The sample code listed below creates the graphics object that I use to write to the image. Dim gr2 As Graphics = Graphics.FromImage(New Bitmap(8...

matlab write image into eps file

In MATLAB, how do you write a matrix into an image of eps format? It seems imwrite does not support eps? convert is not working on the Linux server I am using $ convert exploss_stumps.jpg exploss_stumps.eps convert: missing an image filename `exploss_stumps.eps' @ convert.c/ConvertImageCommand/2838 Any idea why? I tried gnovi...

How can I modify the icon on a treenode in C#, such as reducing opacity, etc?

I want to be able to dynamically modify the image in a c# treeview. Specifically, I would like to reduce the opacity in certain cases of certain images. I know that I can add extra icons to the imagelist that is bound to the treeview, but as cases like this add up, the extra icons will get to be too much. Is there a way to access the ...

How can I overlay one image onto another?

I would like to display an image composed of two images. I want image rectangle.png to show with image sticker.png on top of it with its left-hand corner at pixel 10, 10. Here is as far as I got, but how do I combine the images? Image image = new Image(); image.Source = new BitmapImage(new Uri(@"c:\test\rectangle.png")); image.Stretch...

Get width of a single character from ttf-font in php?

Hello I'm creating an dynamic image, which creates headers on my page using PHPs GD-library. The problem is, that I need a line-wrapping system. It's not a problem itself, but first I need to get the width (in pixels) of current character. I'm pretty curious about this, is there any way? Or do I need to manually specify width of every ...