2010년 3월 12일 금요일

충돌 알고리즘

1) Fast 3D Triangle-Box Overlap Testing (삼각형과 박스의 충돌 검사)
    홈페이지 주소 : http://www.acm.org/jgt/papers/AkenineMoller01/ 이런연결 끊어졌네요..ㅡㅡ;

2) A Fast Triangle-Triangle Intersection Test (삼각형대 삼각형 충돌검사)
   홈페이지 주소 : http://www.acm.org/jgt/papers/Moller97/ 끊어짐.

3) Fast, Minimum Storage Ray-Triangle Intersection (직선과 삼각형의 충돌검사)
   홈페이지 주소 : http://www.acm.org/jgt/papers/MollerTrumbore97/ 끊어짐.


Collision Detection

http://code.google.com/p/gjkd/
http://code.google.com/p/mpr2d/

2010년 3월 11일 목요일

서버에서 다운 받기 - Objective-c

erica 예제 c3-06-Synchronous Downloads


NSURL *url = [NSURL URLWithString: [urlArray objectAtIndex:[which intValue]]];
NSMutableURLRequest *theRequest = [NSMutableURLRequest requestWithURL:url];
NSURLResponse *response;
NSError *error;

NSData* result = [NSURLConnection sendSynchronousRequest:
theRequest
theRequest returningResponse:&response error:&error];



덤으로 무비 플레이어

- (void) startPlayback : (id) sender
{
MPMoviePlayerController* theMovie=[[MPMoviePlayerController alloc] initWithContentURL:[NSURL fileURLWithPath:self.savePath]];
    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(myMovieFinishedCallback:) name:MPMoviePlayerPlaybackDidFinishNotification object:theMovie];
[theMovie play];
}