香港渣打馬拉松 2014 相片收集區
Water
|
02/17/2014
|
HD quality of YouTube vs Vimeo
Water
|
02/09/2014
|

Testing uploading a 1080p video clip from GoPro to two famous video sites, YouTube and Vimeo.

Although YouTube supports both 720p and 1080p, but the HD video quality is unacceptable. It is due to YouTube's bitrate is limited to 3Mbps for 720p and 6Mbps for 1080p. If you upload a high bitrate video, YouTube will re-encode for you and the result is very bad. So if you are going to use YouTube for

Continue Reading

Using iOS 7 text to speech
Water
|
02/05/2014
|

iOS 7 provides powerful text to speech (TTS) support. Here is a simple example:

NSString *language = @"zh-HK";    // set language, zh-HK will speak cantonese
NSString *string = @"你好嗎";
AVSpeechSynthesizer *synthesizer = [[AVSpeechSynthesizer alloc]init];
AVSpeechUtterance *utterance = [AVSpeechUtterance speechUtteranceWithString:string];
utterance.rate = AVSpeechUtteranceDefaultSpeechRate;
utter

Continue Reading

XCode4TemplateForXCode5
Water
|
01/28/2014
|

In Xcode 5, the default project template will create a new project using storyboard and use new API for iOS 7 only.

This repo ported older project under Xcode 4 to Xcode 5, so that you can easily create project that supports both iOS 6 and iOS 7. It is useful if you want to:

  1. Using xib instead of storyboard.
  2. Support both iOS 6 and iOS 7.

Installation

Copy "XC4 Installation" folder in this r

Continue Reading

Suppress ".. is deprecated" warning in code block
Water
|
01/28/2014
|
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- (void) methodUsingDeprecatedStuff {
    //use deprecated stuff
}
#pragma clang diagnostic pop