iOS : Getting screenshot - iphone

Guys I'm looking for the way to retrieve the application screenshot by mean other than CoreGraphics.
I know that Apple has recommended to do it using CoreGraphics here
But I have an issue by doing so when drawing on UIView using UIBezierPath which I've described it here.
So does anyone know any alternative of getting the screenshot of the application by means other than CoreGraphics?

That is pretty mush the only way, but if really can't try guiding the user into pressing the home and power button at the same time.

Related

iOS iPhone finger paint-like app, is there a built-in canvas or open source projects to help me get started?

I need to implement on-screen drawing feature within one of my apps. I would imagine it would be an on-screen transparent overlay. I'm looking to be able to trace the finger path and leave a line, select colors and have erase/undo feature.
I did some research of what's currently on the app store, and a lot of those apps look similar and use similar brushes.
Something tells me that they look too much alike for this to be a coincidence. Does apple provide any built-in finger painting canvas, or are there some widely-known open source projects for on-screen drawing?
Thank you!
I ran into the same thing while looking for examples when I got started with drawing, so I released my efforts as a sample project called SimpleDrawing. I tried to keep things basic while supporting most/all of the standard drawing tools and operations.
There is the GLPaint project, which you can get here.
Other than that, you could use CoreGraphics & -touchesBegan:withEvent: if you wanted.

iPhone SDK - Expanding Buttons like in the camera app

I am curious as to whether or not there is an open source solution to replicate the flash button in the iOS camera applicaiton.
I have seem many other apps use this, but there doesn't seem to be a native way, so I assume there is a common source out there.
It is possible to get the flash button by using UIImagePickerController class, but most of the camera apps out there don't seem to be using this (or perhaps they subclass it, which is against apple's terms).
I am looking for a way to replicate the expanding behavior of the button. Any thoughts?
It doesn't sound too hard.
The way I'd do it is to separate the right curve of the button (as images), and make a UIView that has the left part of the button and the right curve as subviews.
When it's tapped, slide the right curve and animate the extra buttons in.
You could use a stretchable UIImage (see UIImage documentation) and then just animate the frame changing.
In the Apple 2010 WWDC Sample code (downloadable via iTunes, otherwise I'd post it here), there are several sample applications which use this control. They call the class ExpandyButton. I realize I'm answering my question, but hopefully someone out there can find this useful.
While looking for a similar solution to this problem I came across this code which was extremely helpful. Similar to ExpandyButton it fit my needs better.
https://github.com/ddebin/DDExpandableButton

Customize Curl animation in iphone?

I want to set animation for my UIView. I am using CurlUp animation for that. My requirement is to use CurlLeft and CurlRight. These are not available in CoreAnimation as I know. So is there any way by which I can handle the CurlLeft and CurlRight. I don't know a lot about OpenGl. But I don't have any problem with that too. Please guide me and provide me any link by which I can handle CurlLeft and right animation using either OpenGL or CoreAnimation.
Thanks a Lot.
For page turning animations, Ole Begemann has done something like that. His code is available on Github. See my answer to this question for a link.
iBook page flip transaction
His sample project is available for download and shows page curling left and right.

What is autoresizesForKeyboard and how does it work?

I was trying to find a way to adjust my screen when keyboard slides up so that the text field being edited (UITextView in my case) slides up and stays in focus instead of getting hidden behind the keyboard.
I saw a few discussion on google groups mentioning - autoresizesForKeyboard -
http://groups.google.com/group/three20/browse_thread/thread/38bdadc89a1f35f8/2f8b92a6058cf136?lnk=raot&pli=1
I was not able to figure out how to use it or find any documentation for it.
Then I saw how Apple recommends to do it -
http://developer.apple.com/library/ios/#documentation/StringsTextFonts/Conceptual/TextAndWebiPhoneOS/KeyboardManagement/KeyboardManagement.html
However autoresizesForKeyboard sounds too intriguingly simple. Can someone please shed some light on this?
autoresizesForKeyboard is part of the Three20 library and is a property of the TTViewController class.
http://api.three20.info/interface_t_t_view_controller.html#acc0ff2c5d115eb977aaac419cb64f62b
"Three20 is an iPhone development library. It's the code that powers the Facebook iPhone app and many other apps in the app store."
http://three20.info/

How to build a "virtual zippo" app?

You probably all know the famous virtual zippo app.
I thought of making such an app too, just for learning objective-c.
THe developer said he has used a video of flame.
How is it possible to play a video inside a UIView?
DO you have any ideas of how to achieving that?
Thanks in advance!
I don't know about a video inside a UIView, but you can use an UIImageView and animate a series of images with it. Here's how.