435
edits
Glozt100sob (talk | contribs) mNo edit summary |
Glozt100sob (talk | contribs) |
||
Line 83: | Line 83: | ||
</gallery> | </gallery> | ||
== | ==Programming Technique== | ||
''NOTICE:'' For your convenient, I packed project folder into Zxing-1.6 folder path. Hence, you have to only | |||
download from the link then uncompressed the file to your hard drive. Then, find Relieve Climate folder under Zxing-1.6/iphone/ | |||
I have created this application using Xcode 3.2 debugging on iOS 4.2 iPad II. According to [http://dl.dropbox.com/u/30247554/zxing-1.6.zip RelieveClimate.xcodeproj], pragmatic program method described as below: | |||
*Relieve Climate application uses UITabBarController outlet and set as a rootController. | |||
*Each tab contains with NavigationController responding to switching between view. | |||
''JourneyIndexViewController'' | |||
*JourneyIndexViewController is a controller contains with ZxingWidgetController class. ZxingWidgetController class inherited from dependency project ZxingWidget.xcodeproj that included to Relieve Climate project. ZxingWidgetController is implemented for enable QR-Code scanner. | |||
*NSUserDefaults called for saving and loading user's datas.(distance, Carbon Dioxide, fuel) | |||
''CheckInViewController'' | |||
*Display a map by calling subclass MKMapview and set map region and span by MKCoordinateRegion and MKCoordinateSpan respectively. | |||
*Enable GPS and update realtime coordination by CLLocationManager subclass and CLLocationCoordinate2D and get the distance from CLLocationDistance. | |||
*Set an accuracy of updating distance by CLLocationAccuracy subclass. | |||
*Calculate Carbon Dioxide amount and fuel number by mathematic operation *,/ | |||
''BrainTrainViewController'' | |||
*Display 'Brain Train Tip' subview by UIWebView path to pdf file. | |||
''JourneySummaryViewController'' | |||
*Pass value from CheckInViewController then contain in .text object, finally, display in view. | |||
''MyRewardViewController'' | |||
*Visualize data by implementing Box2D physics engine. Create collision environment aka. world | |||
*Add body (diamond shape) to world by function addPhysicalBodyForView: | |||
*Set center of mass to body using CGPoint subclass. | |||
*Set density, friction, restitution calling b2PolygonShape. | |||
==You want to try Relieve Climate?== | ==You want to try Relieve Climate?== |
edits