Thursday, April 18, 2013

[ios] IBOutlet but no synthesize


In Xcode 4.4 (specifically, the LLVM 4.0 Compiler), synthesis of properties happens by default if there's no @synthesize directive. It's equivalent to:
@synthesize nameField = _nameField;

Wednesday, March 13, 2013

ffmpeg strip video


ffmpeg strip video, from http://howto-pages.org/ffmpeg/#strip
ffmpeg -i mandelbrot.flv -vn -acodec copy mandelbrot.mp3

convert m4a to mp3
ffmpeg -i xxxx.m4a -acodec libmp3lame -ab 128k xxxx.mp3

Monday, January 7, 2013

Android Eclipse on Ubuntu

1. download Eclipse 4.2.1 linux 64bit, and extract it
2. sudo apt-get install openjdk-6-jdk
3. run eclispe
4. goto Help -> Install New Software
5. add https://dl-ssl.google.com/android/eclipse/ and install
6. download android sdk
7. got an error -> adb: no such file
8. do "sudo apt-get install ia32-libs"

Thursday, January 3, 2013

Build directshow strmbase.lib in Windows 8

To build directshow strmbase.lib, here is the step when using dx9b.
Open \dx90bsdk\Samples\C++\DirectShow\BaseClasses\baseclasses.sln
in Visual Studio 2012.
Compile and fix error:
1. add c/c++ prepocessor definitions:
    POINTER_64=__ptr64
2. fix for loop variable declare

outputq.cpp:
for (long iDone = 0;
-->
long iDone;
for (iDone = 0;

winutil.cpp:
for (UINT Count = 0;Count < Result;Count++) {
->
UINT Count = 0;
for (Count = 0;Count < Result;Count++) { 


wxdebug.cpp
static g_dwLastRefresh = 0;
->
static int g_dwLastRefresh = 0;



3. sysclock.cpp, add g_Templates & g_cTemplates to fix link error
//#ifdef FILTER_DLL
/* List of class IDs and creator functions for the class factory. This
   provides the link between the OLE entry point in the DLL and an object
   being created. The class factory will call the static CreateInstance
   function when it is asked to create a CLSID_SystemClock object */
CFactoryTemplate g_Templates[1] = {
    {NULL, &CLSID_SystemClock, CSystemClock::CreateInstance}
};
int g_cTemplates = sizeof(g_Templates) / sizeof(g_Templates[0]);
//#endif    


Monday, November 19, 2012

[wp8] windows phone 8 can't download app from market

I got the new lumia 920 but after I setup microsoft account, I can't download apps from market.
After surfing the net, there is one reason that the phone time is incorrect.
SO, I go to setting -> time -> and disable auto. then setup my timezone and time correctly.
I can download apps now!
what a waste of time!!