thumbnails

PHP Thumbnail Class

倾然丶 夕夏残阳落幕 提交于 2019-12-03 07:57:20
I am looking for a solid PHP thumbnail generating class. Does anyone know any good ones that are open-source? I could write one, but I really don't want to. The one thing I hate most about PHP is manipulating images with GD and Imagemagick. Does anyone have any suggestions? Use phpThumb() . Its a script that internally uses GD library and/or ImageMagick (whichever is available and whichever it thinks is best for the job) to perform basic image manipulation tasks, including thumbnail generation and square thumbnail generation. You can use it like this: <!-- best fit --> <img src="/phpThumb

Django: how to serve user-submitted images & thumbnails from separate, multiple servers?

柔情痞子 提交于 2019-12-03 07:56:39
问题 For my Django site, I'd like to: Accept images submitted by users Generate thumbnails from those images Put both the original images and the thumbnails onto separate, multiple servers that are dedicated to serving images I need multiple, separate servers to serve the images/thumbnails to ensure I have enough IO performance. What is the best way to build a distributed image serving system like this? Any open source software that would help? Thanks. 回答1: This sounds like a job for distributed

PIL: Image resizing : Algorithm similar to firefox's

允我心安 提交于 2019-12-03 07:36:48
问题 I'm getting about the same bad looking resizing from all the 4 algorithms of PIL >>> data = utils.fetch("http://wavestock.com/images/beta-icon.gif") >>> image = Image.open(StringIO.StringIO(data)); image.save("/home/ptarjan/www/tmp/metaward/original.png") >>> >>> image = Image.open(StringIO.StringIO(data)); image.resize((36,36), Image.ANTIALIAS).save("/home/ptarjan/www/tmp/metaward/antialias.png") >>> image = Image.open(StringIO.StringIO(data)); image.resize((36,36), Image.BILINEAR).save("

In a TIFF create a Sub IFD with thumbnail (libtiff)

a 夏天 提交于 2019-12-03 06:43:25
I know thumbnail.c includes some code that creates a thumbnail and places it in a sub IDF, but there is a lot going on in that code (generating the thumbnail, applying a contrast curve, etc.) and I am having difficulty reproducing just writing a thumbnail. Google has not been any help either. My question is, after I have opened an output file and have a TIFF*, I have my thumbnail data all ready to go (as well as my main image data), how do I add them in such a way that the thumbnail is in a sub IFD of the main image IFD? So after digging around through the libtiff source code for a while, I

Custom thumbnails for file types with Paperclip

那年仲夏 提交于 2019-12-03 05:11:45
问题 I'm using Paperclip with a Ruby on Rails to attach assets to a model, these assets can be any file type and currently thumbnails are only being generated if the asset is an image. I'd like to be able to display a different default image for other files, either by generating a thumbnail of the files on upload, or setting something up with the default_url but so far I can't find any resources to help with this and am getting no where on my own. My model is as follows: class Asset < ActiveRecord

generate image (e.g. jpg) of a web page?

时光怂恿深爱的人放手 提交于 2019-12-03 05:02:55
I want to create an image what a web page looks like, e.g. create a small thumbnail of the html + images. it does not have to be perfect (e.g. flash /javascript rendering). I will call use the code on linux, ideally would be some java library, but a command line tool would be cool as well. any ideas? Try CutyCapt , a command-line utility. It uses Webkit for rendering and outputs in various formats (SVG, PNG, etc.). Colin Pickard you can get it nearly perfect, and cross platform too, by using a browser plugin. FireShot or ScreenGrab for Firefox. 6 Google Chrome Screenshot Webpage Capture

Get YouTube or Vimeo Thumbnails in one shot with jQuery

偶尔善良 提交于 2019-12-03 04:07:36
I'm trying to put YouTube thumbnail and Vimeo thumbnail together in the same script, but its not really easy for me because I'm a new to jQuery. I would to ask if somebody could take a look to this jQuery script that works fine in any browser: http://jquery-howto.blogspot.com/2009/02/how-to-get-youtube-video-screenshot.html I've also seen the question: Get img thumbnails from Vimeo? , but there's nothing about how to do it with jQuery. I think it should be very easy to make for who already know the jQuery coding, and it would be the definitive solutions for who's going to make a Tumblr theme

Creating Thumbnail from Video - Improving Speed Performance - AVAsset - iPhone [duplicate]

梦想的初衷 提交于 2019-12-03 03:24:01
This question already has an answer here : Grabbing First Frame of a Video - Thumbnail Resolution - iPhone (1 answer) I am using code based on the code in the following thread to generate a video thumbnail : Getting a thumbnail from a video url or data in iPhone SDK My code is as follows : if (selectionType == kUserSelectedMedia) { NSURL * assetURL = [info objectForKey:UIImagePickerControllerReferenceURL]; AVURLAsset *asset=[[AVURLAsset alloc] initWithURL:assetURL options:nil]; AVAssetImageGenerator *generator = [[AVAssetImageGenerator alloc] initWithAsset:asset]; generator

Stretch, resize, or thumbnail an image using Perl

巧了我就是萌 提交于 2019-12-03 03:13:49
How can I stretch or resize an image (of any format) using a Perl script? Ranguard I'd recommend Image::Imlib2... if you can install imlib2 on your machine See documentation: Image::Imlib2 use Image::Imlib2; # load image from file my $image = Image::Imlib2->load("in.png"); # get some info if you want my $width = $image->width; my $height = $image->height; # scale the image down to $x and $y # you can set $x or $y to zero and it will maintain aspect ratio my $image2 = $image->create_scaled_image($x,$y); # save thumbnail to file $image2->save("out.png"); You might also be interested in Image:

Url of large image of a YouTube video

北城以北 提交于 2019-12-03 02:14:08
I'm interested in getting a preview image of a youtube video for my application I'm using the url to the previews: http://img.youtube.com/vi/EqWRZrupLrI/0.jpg but this has little two black rows, up and down, and I wish it were bigger. I have read that the 0 is the bigger picture. anyone know if it is possible to obtain a url with a better image?, for my project, I need the image is on a url I appreciate the help Regards :) 0.jpg is the full-size 480p thumbnail and there is no bigger thumbnail except for full HD videos ( maxresdefault.jpg ). But why do you expect a bigger thumbnail for such a