128Adding Alpha Blending Mode to Quartz Composer
Courtesy of Kineme.
Courtesy of Kineme.
Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB. Always check whether delegates are set in IB.
Ps. Always check whether delegates are set in IB.
http://developer.apple.com/samplecode/CallJS/
PSP svn cocoa_call_AS2
Enable Debug Menu in Safari 4.0:
defaults write com.apple.Safari IncludeInternalDebugMenu 1
via http://trac.webkit.org/wiki/WebDevelopers
Also, an interesing option is to modify the .nib file of Safari and insert a new menu: http://pointum.com/safari-tweaks.html
Apparently has to be put into recovery mode.
http://discussions.apple.com/thread.jspa?messageID=9651285 http://support.apple.com/kb/HT1808
source: http://github.com/mrRay/vvosc/tree/master docs: http://www.vidvox.net/rays_oddsnends/vvosc_doc/
after following the instructions in the docs, i get the following error (iPod Touch 2nd, OS3.0 beta 5)
/Users/username/Desktop/Test/build/Debug-iphoneos/Test.app: object file format invalid or unsuitable
After some googling, I came across this, and it seems to do the trick.
add:
$(SDKROOT)/ResourceRules.plist
to the Code Signing Resource Path. Why exactly it's working is anybody's guess.
~
This might also be worth a look: liblo: Lightweight OSC implementation
#include
//#include <sys/types.h> //#include <sys/socket.h>
//#include <net/if_dl.h>
(NSString*)getWiFiIPAddress {
BOOL success; struct ifaddrs addrs; const struct ifaddrs cursor;
success = getifaddrs(&addrs) == 0; if (success) { cursor = addrs; while (cursor != NULL) { if (cursor->ifa_addr->sa_family == AF_INET && (cursor->ifa_flags & IFF_LOOPBACK) == 0) // this second test keeps from picking up the loopback address { NSString name = [NSString stringWithUTF8String:cursor->ifa_name]; if ([name isEqualToString:@"en0"]) { // found the WiFi adapter return [NSString stringWithUTF8String:inet_ntoa(((struct sockaddr_in )cursor->ifa_addr)->sin_addr)]; } }
cursor = cursor->ifa_next;
}
freeifaddrs(addrs);
} return NULL; } via http://mattbsoftware.blogspot.com/2009/04/how-to-get-ip-address-of-iphone-os-v221.html
struct
a collection of types, composite data type, composition, "user-definded data structure"
struct Test {
char* name;
int nr;
float f;
};
Name of type is "struct Test", and not "Test" alone.
struct Test myNewTest
Semicolon after closing parethesis is essentional.
Access composed types with dot-syntax:
myNewTest.name = "hjkjnk";
myNewTest.nr = 32;
myNewTest.f = 2.2424;
typedef a shorthand, an alias for a type, for ease of readability.
typedef int MyType
"MyType n;" would be equal to "int n;"
enum "introduces a symbolic name for an integer constant"
enum direction_enum {LEFT, RIGHT}; / LEFT -> 0, RIGHT -> 1; / enum direction_enum x = LEFT;
typedef enum
typedef enum {
LEFT;
RIGHT;
} direction;
declatation:
-(void)myFunction:(direction)LEFTorRIGHT;
call: -(void)myFunction:LEFT;
typedef struct
typedef struct objectInfo_ { CGPoint origin; NSString name; NSColor color; } objectInfo
Shortcut. Instead of writing 'struct objectInfo', write 'objectInfo'. The keyword 'objectInfo' seems to be optional.