{"action":"created","issue":{"url":"https://api.github.com/repos/PistonDevelopers/image/issues/725","repository_url":"https://api.github.com/repos/PistonDevelopers/image","labels_url":"https://api.github.com/repos/PistonDevelopers/image/issues/725/labels{/name}","comments_url":"https://api.github.com/repos/PistonDevelopers/image/issues/725/comments","events_url":"https://api.github.com/repos/PistonDevelopers/image/issues/725/events","html_url":"https://github.com/PistonDevelopers/image/issues/725","id":296473169,"number":725,"title":"Zero frames in a gif","user":{"login":"calum","id":22115035,"avatar_url":"https://avatars1.githubusercontent.com/u/22115035?v=4","gravatar_id":"","url":"https://api.github.com/users/calum","html_url":"https://github.com/calum","followers_url":"https://api.github.com/users/calum/followers","following_url":"https://api.github.com/users/calum/following{/other_user}","gists_url":"https://api.github.com/users/calum/gists{/gist_id}","starred_url":"https://api.github.com/users/calum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/calum/subscriptions","organizations_url":"https://api.github.com/users/calum/orgs","repos_url":"https://api.github.com/users/calum/repos","events_url":"https://api.github.com/users/calum/events{/privacy}","received_events_url":"https://api.github.com/users/calum/received_events","type":"User","site_admin":false},"labels":[{"id":102141892,"url":"https://api.github.com/repos/PistonDevelopers/image/labels/bug","name":"bug","color":"fc2929","default":true},{"id":102141895,"url":"https://api.github.com/repos/PistonDevelopers/image/labels/help%20wanted","name":"help wanted","color":"159818","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-02-12T18:12:09Z","updated_at":"2018-02-13T20:46:10Z","closed_at":null,"author_association":"NONE","body":"Hi there,\r\n\r\nI'm struggling to get the frames from a gif image. I've tried a couple of different gifs and they all come out as just 1 frame. Am I doing something obviously wrong?\r\n\r\n```rust\r\n    let mut f = File::open(filename).expect(\"File not found\");\r\n\r\n    let mut decoder = gif::Decoder::new(f);\r\n\r\n    let mut frames = decoder.into_frames().expect(\"error decoding gif\");\r\n\r\n    for (i, frame) in frames.enumerate() {\r\n        let mut image = frame.into_buffer();\r\n\r\n        // display the image:\r\n        //render_image(image.convert(), width, height);\r\n\r\n        println!(\"Frame: {}\", i);\r\n        thread::sleep(time::Duration::from_millis(100));\r\n        println!(\"next frame...\");\r\n    }\r\n```\r\n\r\nEvery time I run this, I only see\r\n```\r\nFrame: 0\r\nnext frame...\r\n```\r\n\r\nThanks for any help!\r\n\r\nCalum"},"comment":{"url":"https://api.github.com/repos/PistonDevelopers/image/issues/comments/365398469","html_url":"https://github.com/PistonDevelopers/image/issues/725#issuecomment-365398469","issue_url":"https://api.github.com/repos/PistonDevelopers/image/issues/725","id":365398469,"user":{"login":"nwin","id":949560,"avatar_url":"https://avatars0.githubusercontent.com/u/949560?v=4","gravatar_id":"","url":"https://api.github.com/users/nwin","html_url":"https://github.com/nwin","followers_url":"https://api.github.com/users/nwin/followers","following_url":"https://api.github.com/users/nwin/following{/other_user}","gists_url":"https://api.github.com/users/nwin/gists{/gist_id}","starred_url":"https://api.github.com/users/nwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nwin/subscriptions","organizations_url":"https://api.github.com/users/nwin/orgs","repos_url":"https://api.github.com/users/nwin/repos","events_url":"https://api.github.com/users/nwin/events{/privacy}","received_events_url":"https://api.github.com/users/nwin/received_events","type":"User","site_admin":false},"created_at":"2018-02-13T20:46:10Z","updated_at":"2018-02-13T20:46:10Z","author_association":"CONTRIBUTOR","body":"You’ll need to use the gif crate directly. Have a look at at the disposal method. It determines how to handle the frames\r\n\r\nhttps://docs.rs/gif/0.9.2/gif/enum.DisposalMethod.html"}}
{"actor":{"display_login":"nwin"}}