gif

(WPF) How to extract frames from multiframe images (tif, gif)

只谈情不闲聊 提交于 2019-12-24 07:59:49
问题 I'm trying to extract thumnail images of each frame in an animated gif. The following code is how I'm tyring to do it, but the thumbnail property of the BitmapFrame instance is always null. Am I doing something wrong? GifBitmapDecoder bd1 = new GifBitmapDecoder( new Uri(thisImage.Path), BitmapCreateOptions.None, BitmapCacheOption.Default); if (bd1.CheckAccess()) { if (bd1.Frames.Count > 1) { foreach (var frame in bd1.Frames) { BitmapSource frameThmb = frame.Thumbnail; if (frameThmb != null)

GIF image not show

岁酱吖の 提交于 2019-12-24 07:35:55
问题 I follow this post to show GIF image. I have tried: #import "ViewController.h" @interface ViewController () @end @implementation ViewController - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view, typically from a nib. UIImageView* animatedImageView = [[UIImageView alloc] initWithFrame:self.view.bounds]; animatedImageView.animationImages = [NSArray arrayWithObjects: [UIImage imageNamed:@"splash.gif"], nil]; animatedImageView.animationDuration = 6.0f;

Tkinter displaying distorted image

亡梦爱人 提交于 2019-12-24 05:20:44
问题 I am trying to display a gif using Tkinter, but when the gif loads it looks very odd. I have pasted screenshots of the original gif and the gif displayed in Tkinter. This does not happen with only one gif, but every gif I use. Original Frame in Gif: Frame seen in tkinter: Here is the code: from Tkinter import * import time as t root = Tk() frames = [] i = 0 while True: try: frames.append(PhotoImage(file='display.gif',format='gif -index %i' %(i))) i += 1 except TclError: break def update(ind):

Is there a way to convert image with R ? JPEG to GIF for example

戏子无情 提交于 2019-12-24 04:12:00
问题 I wish to display images in a tcltk window (not in a R device) using R but the simpliest method (below) supports only GIF files : require(tcltk) tcl("image","create","photo", "imageID", file="a.gif") w <- tktoplevel() l <- ttklabel(w, image="imageID", compound="image") tkpack(l) and I my files are png/jpeg (file containing histograms generated by my program itself) someone has an idea to do that conversion ? thank you 回答1: Despite the warnings this seems to succeed: png("test.png") plot(1,1)

Is there a way to convert image with R ? JPEG to GIF for example

旧时模样 提交于 2019-12-24 04:11:56
问题 I wish to display images in a tcltk window (not in a R device) using R but the simpliest method (below) supports only GIF files : require(tcltk) tcl("image","create","photo", "imageID", file="a.gif") w <- tktoplevel() l <- ttklabel(w, image="imageID", compound="image") tkpack(l) and I my files are png/jpeg (file containing histograms generated by my program itself) someone has an idea to do that conversion ? thank you 回答1: Despite the warnings this seems to succeed: png("test.png") plot(1,1)

How to Convert animated .gif into .webm format in Python?

喜欢而已 提交于 2019-12-24 03:25:59
问题 I have a web application built on Django where images and animated Gif can be uploaded. However GIF takes long time to load. I was thinking of converting all uploaded gif into webm format and show it on the frontend using HTML5 video tag. I searched a lot for doing this in Python but could not find specific solution. I found this solution. But I want to know is it possible to convert gif into webm while uploading in python or is there any library in python from which this conversion can be

GIFs changing randomly

旧时模样 提交于 2019-12-24 03:04:49
问题 I got a problem with GIFs and Javascript. I got different GIF-animations which are all the same format and I want them to change randomly after they are played one time. I tried to solve this with Javascript but I only could make it work with an exact time to make the change and not when each GIF-animation is finished (they are all finishing at different times). <html> <head> <script type="text/javascript"> <!-- var ima = []; ima[0] = 'bilder/bild1.gif'; ima[1] = 'bilder/bild2.gif'; ima[2] =

How to fix .gif with corrupted alpha channel (stuck pixels) collected with Graphicsmagick?

孤街醉人 提交于 2019-12-24 01:57:15
问题 I want to convert an .avi with alpha channel into a .gif. Firstly, I use ffmpeg -i source.avi -vf scale=720:-1:flags=lanczos,fps=10 frames/ffout%03d.png to convert .avi to sequence of .png's with aplha channel. Then, I use gm convert -loop 0 frames/ffout*.png output.gif to collect a .gif. But it seems that pixels of the output.gif just get stuck when something opaque is rendered on top of the transparent areas. Here's an example: As you can see the hearts and explosions do not get derendered.

Print gif using java on a 4x6" paper

你说的曾经没有我的故事 提交于 2019-12-23 21:26:49
问题 What is the best way in Java to print a gif given as byte[] or ByteArrayInputStream on a paper with a size of 4x6 inches? This: PrintRequestAttributeSet aset = new HashPrintRequestAttributeSet(); aset.add(new MediaSize(4, 6, Size2DSyntax.INCH)); aset.add(new Copies(1)); PrintService[] pservices = PrintServiceLookup.lookupPrintServices(DocFlavor.INPUT_STREAM.GIF, aset); DocPrintJob printJob = pservices[0].createPrintJob(); Doc doc = new SimpleDoc(sap.getGraphicImageBytes(), DocFlavor.INPUT

Animated gif in Delphi XE 3 forms [duplicate]

走远了吗. 提交于 2019-12-23 20:05:53
问题 This question already has answers here : Closed 6 years ago . Possible Duplicate: How to use Animated Gif in a delphi form I recently updated my version of Delphi 7 to Delphi XE3 . Using Delphi 7, I used a component to put a GIF on a TImage, delphi XE3 already has compatibility with gif's, it is not necessary to install any additional third party components. my question is: when I attach the gif to TImate, it becomes static, shows only the first frame. is there any command for this? like