I have implementing pdf application for ipad.Now i want to set brightness in my application.Is it possible?Please help me for this problem.
Thanks in advance.
Hi
I have to do some different views containing 72 LED lights. I built an LED Class so I can loop through the LED's and set them to different colors (Green, Red, Orange, Blue None etc.).
The LED then loads the appropriate .png.
This works fine, I loop over the LED's and set them.
Now I know that at some time they will need to not just turn on/off change color, but will have to turn on with a small delay. Like an equalizer.
I have a 5-10 views containing the 72 LED's and I would like to achieve the above with the minimum amount of memory/CPU strain.
for(LED *l in self.ledArray) {
[l display:Green];
}
I simply loop as shown above and inside the LED is a switch case that does the correct logic.
If this were actual LED's and a microController I would use sleep(100) or similar in the loop, but I would really like to avoid stuff like that for obvious reasons.
I was thinking that doing a performOnThread withDelay would really be consuming, so would UIView animation changing the alpha and NSOperation would also be a lot of lifting for a small feature.
Is there a both efficient and clever way to go around this?
Thanks for any inspiration given:)
I know to use glGet to get various parameters. I need to know how to get the current GL_FRAMEBUFFER_OES and get the GLuint type framebuffer id.
I need to use renderToTexture. This will make one of the classes code easier when switching back to normal framebuffer.
Hello. I am looking for those arrow icons (a left white arrow and a white right arrow) that are used on the lower toolbar of the Photo Library (or Camera Roll). I also have seen them on the Facebook app and some other custom apps. I am surprised that they are not built in "UIBarButtonSystemItem" icons. Can anybody point me to these icons?
I have an application that I'm currently building that requires me to display a visual update on the application it self. example:
The weather app displays 14 degrees celcius and some clouds as its application icon. When the weather changes there is an update to the way the icon looks without having to open the weather app. The applications icon changes to reflect the update in weather. You can then open the weather app to get more information if need be.
In my application I need to have an update system like that which shows the user information without opening the application. If they would like more information they can open the application then.
I have no idea how to accomplish this task at the moment. I hope someone will be able to help or point me in the right direction. Thank you for your time.
Hi,
I want make simple application in which i want to play sound with text.
The real problem how i synchronize my existing sound file with the animated glowing text.If the first word is small and other will be big then how i play sound with particular word? Is their require an timer?
Has anyone had any experience of this? Is it easy? I know very little C, but all I want to do is package the web app as a native app. Is that allowed by Apple anyway?
Thanks!
Is it possible to load a short video file and - once loaded - select a specific frame and display that frame in a view? If there is no native support for this, how about an open source alternative?
Thanks in advance.
-Doug
i have a c++ class with CGrect variable and i'm getting segfault when trying to access it.
class Parent
{
//with some virtual functions/dtors
};
class Child
{
public:
void SetRect(CGRect rect) { mRect = rect; }
CGRect GetRect() { return mRect; }
int GetIndex() { return mIndex; }
private:
CGRect mRect;
int mIndex;
};
i'm doing
CGRect rect = childPtr->GetRect();
from object c code and it segfaults.
I printed *childPtr just before the call and rect looks fine with intended data value.
int index = childPtr->GetIndex();
from same object c code(*.mm), works fine though.
Any idea why I'm getting segfaults?
Thank you
edit -
It's got something to do with virtual functions.
(gdb) p singlePuzzlePiece-GetRect()
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000001
0x00000001 in ?? ()
Cannot access memory at address 0x1
The program being debugged was signaled while in a function called from GDB.
GDB remains in the frame where the signal was received.
To change this behavior use "set unwindonsignal on"
Evaluation of the expression containing the function (at 0x1) will be abandoned.
(gdb)
Somehow, the function is not properly compiled?
Hi.
Among many animation scenarios, there are times when I want an object to move a straight line then change direction, move another straight line and so forth.
Assuming I would use either UIImageView or CABasicAnimation with image arrays.
Does it make difference to provide more images when the object is moving in a straight line?
For example,
point1 ---------point2 ------- point3 (all points are in a straight line)
Providing an image at point2 to UIImageView or CABasicAnimation, gives any better animation result, assuming I don't need to change the animation speed along the course?
If I were flashing each image myself, yes it would make the animation look smooth, but I'm giving the images to UIImageView/CABasicAnimation, and wonder what they do.
Thank you
We are creating a video intensive app and want to be sure that adaptive streaming is required (given that we need to write an automated transcoding and segmentation system to support this). Does anyone know if the YouTube app is using adaptive streaming?
I have a root view controller with no nib file,
I tried adding this at cellForRowAtIndexPath as that passes in a UITableView as tableView.
So I put :
tableView = [[UITableView alloc] initWithFrame:self.view.frame style:UITableViewStyleGrouped];
It ran with no error but it didnt seem to change anything.
I have UITextView for text, after user press DONE, I convert text to UIImageView and show it. It works with one line of text very good,
and Screenshot 1
. But if user types two lines, or more: the result is still one line??? Screenshot 2
I want to display two or more lines in UIimageView
Can anybody help me! Thank you very much!
Here is my code:
-(UIImage *)convertTextToImage : (ObjectText *) objT;
{
UIGraphicsBeginImageContext(CGSizeMake(([objT.content sizeWithFont:objT.font].width+10), ([objT.content sizeWithFont:objT.font].height+10)));
[[objT getcolor] set];
[objT.content drawAtPoint:CGPointMake(5, 5) withFont:objT.font];
UIImage *result = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return result;
}
In what format the content data is placed on server so that when user buy content from server he can use new content . also if this data is in compressed format then how to uncompress it in application ?
Hi guys!
First of all, sorry for my posibly bad english...
I got a surely big stupid question...
In my enterprise have an automatic door system, that is opened with a HTTP GET request to a file.
Example:
http://ipaddress/rc.cgi?o=1,50
Where the o=number indicates the amount of seconds that the automatic door will run.
The is no need for authentification or nothing (that is made by LAN Radius).
So, the question is...
How can I make a single button (for example in the springboard) that when you touch it, runs the GET request?
You thing that it should be possible with NSURLConection ?
Thanks for all
Hello. I am a student programmer who has taken up Objective-C on my free time as my college doesn't teach it. We have only used Java and basic C so far. I am in the middle of making a program for the iPod and was wondering if there was any type of way to call a method in a class similar to the way a Focus Listener does in Java? I have a view that I would like to call a refresh method (to update the newly inputted titles of buttons from another view) when the view is put at the top and visible again. Is this too easy or is there a more methodical way of doing that? I have tried to just call the method from the other view class but it does not seem to work (says the other class is either undefined or may not accept the method call and crashes on execution).
Any insight would be appreciated. Thank you for your time.
I checked this posting, so it was impossible to do it.
But it's old posting, and somebody are saying me there is an app which can change wallpaper(lock screen). Is this allowed now?
I have an app with a tab bar, and nav controllers in each tab. When user shakes the device, a UIImageView appears as a child view in the nav controller. But the UIImageView must contain a special image, depending on the device's current orientation.
If I write just
- (void)willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)
if (interfaceOrientation == UIInterfaceOrientationPortrait|| interfaceOrientation == UIInterfaceOrientationPortraitUpsideDown) {
//Code
}
else if (interfaceOrientation == UIInterfaceOrientationLandscapeRight||interfaceOrientation == UIInterfaceOrientationLandscapeLeft) {
//Code
}
}
The view just goes crazy if user rotated the device before shaking. Is there a method to get iPhones current orientation?
what is the best way to check the strength of a password in iOS development?
I came across this post:
What is the best way to check the strength of a password?
but this is not iOS specific. My question is - Does Apple or third party libraries provide any libraries by default which I can use to check if the user entered a secure password?
If not, then as the above post says, is using regular expressions the best way?
Does Apple have any requirements which our app needs to implement to make sure user has a secure password?
I am planning on using the keychain to store the password.
I'm fairly new to Objective-C and am confused on what falls under the unbrella of a "private API" that could cause Apple to reject my app. Does this include adding methods to existing classes? For example, I found some code on stackoverflow to recolor the tab bar icons for UITabBars with this extension to the UITabBarItem class. Is this considered a "private API"? If not, what does?
@interface UITabBar (ColorExtensions)
- (void)recolorItemsWithImage:(UIImage *)image shadowColor:(UIColor *)shadowColor shadowOffset:(CGSize)shadowOffset shadowBlur:(CGFloat)shadowBlur;
@end
My view hierarchy looks like this:
tab bar - navigation bar - table view - view 1 - view 2 (UIWebView)
How can I rotate view 2 so it can be displayed in both landscape & portrait mode?