I am trying to figure out how to take a screen capture feed and send it to an iOS device (this case An iPad) and images are displayed on the screen, every new image is sent as an update, while clearing the old from memory
I'm just starting the basics, That's why I have to load the screenshot from the simulator desktop and on the screen Trying to display, and then to change the image as soon as I take a new screenshot, and either delete the old one, then I would like to move the same name or to overwrite the old screenshots I can change the name of this (in this way the context will still tell in the programming code correctly).
I tried to use a button that reloaded my UIImageView:
- (IBAction) button pressed: (ID) sender {[UIImageView set Image: screencache]; } Where the screen capture is the name of the UIIMA veve, with the hope that it reloads the existing referenced image file, but clicking on the button causes the program to exit the simulator And goes back to the Simulator's home screen.
Am I using the wrong object when it is done through UIMAview? Do they have an existing program / tutorial on this?
I will try to reverse engineer VNC for the iPhone, but the amount of copyright issues and advanced programming features are well beyond me.
P> Once I can do something through Xcode, I am trying to apply the same thing through mono-touch to see which The language is easy to use and is more favorable for beginners.
Thanks for the help, ~ Chris
Header: #import & lt; UIKit / UIKit.h & gt; @ Interface Screen CaptureAudio View Controller: UIViewController {IBOutlet UIImageView * ScreenCapture; IBOutlet UIBarButtonItem * Update; } @ Property (Nonomatic, Replacement) IBOutlet UIImageView * ScreenCapture; @protecti (nanatomic, retten) ibotlet UIBarButtonItem * update; - (IBAction) button pressed: (ID) sender; @end .m: #import "Screen_Capture_3ViewController.h" @Exposition Screen_Capture_3ViewControllerSynchesiveScreenCapture; @ Synthesis update; - (IBAction) button pressed: (ID) sender {[UIImageView setImage: ScreenCapture]; } Everything else remains while selecting "View-based application", and I connect the Screensaver with UIMAJView in the interface builder, as well as updates and buttons interface In UIBarButtonItem is pressed on Builder.
setImage is an example method, not a class method, so you can not send it directly
Place your current code with your question for the header (but only the property should be marked as IBOutlet):
@ interface screencache audio view controller: UIViewController {UIImageView * ScreenCapture ; UIBarButtonItem * update; } @ Property (Nonomatic, Replacement) IBOutlet UIImageView * ScreenCapture; @protecti (nanatomic, retten) ibotlet UIBarButtonItem * update; - (IBAction) button pressed: (ID) sender; @end In your implementation, your event handler must be:
- (IBAction) button pressed: (ID) Sender {UIImage * NewImage = [UIImage imageWithContentsOfFile: @ "pathToImage.png"]; [Screen Capture Set Image: New Image]; }
Comments
Post a Comment