Can you load gif image in the contentViewController?
I saw the second screenshot in the README has an animation, so just wonder how does it implement?
Use a .mp4 instead, it's smaller and works way better (it will loop automatically)
On Thu, Aug 27, 2015 at 12:26 PM, Wei [email protected] wrote:
I saw the second screenshot in the README has an animation, so just wonder how does it implement?
— Reply to this email directly or view it on GitHub https://github.com/mamaral/Onboard/issues/78.
+1 to what @chrisballinger said.
So I need to load mp4 as background in the OnboardingViewController ? OnboardingContentViewController is not able to load mp4 yet?
@willthink could you find any solution to this?
@willthink I misread your initial question - if you want a gif/video that is currently not supported for the content pages, only the primary onboarding background.
@FabKremer The only solution I can think of currently is to customize the internals of OnboardingContentViewController to support it.
Hi I saw this issue open and wanted to give a hand, I added video support to OnboardingContentViewController, just need to create the instance with a video url and it will be loaded in the background similar to OnboardingViewController. There is also an example and some test for this.
The only catch is that MPMoviePlayerController doesn't support multiple videos at the same time, so I added a thumbnail to show when the video is stopped but it also has to wait until the video is loaded to be visible
I have a fork with the changes (https://github.com/estebansotoara/Onboard/tree/ContentViewControllerVideoSupport), you can check it out and if you like it I can make a PR
Thanks @estebansotoara!
Another solution is to try using SDWebImage, AFAIK their UIImageView category supports GIFs?
Yes, SDWebImage supports GIF, I actually had to remove it as a requirement for a project I'm working on, but I think we'll have to add SDWebImage as a dependency.
I just did the PR #95 and let me see what can I do for the actual GIF this week.
Hello @mamaral I added GIF support using FLAnimatedImage as SDWebImage would be an unnecessary overkill, check it out https://github.com/estebansotoara/Onboard/tree/ContentViewControllerGifSupport
Also had to change back to [[NSNotificationCenter defaultCenter] removeObserver:] as the [[NSNotificationCenter defaultCenter] removeObserver: keyPath:] version is not very friendly with XCTestExpectation and as long it is on the dealloc it is not actually really harmful.