WhirlyGlobe  1.2
A 3D interactive globe toolkit for iOS
WhirlyGlobeView Class Reference

#import <GlobeView.h>

Inheritance diagram for WhirlyGlobeView:
EAGLView

List of all members.

Public Member Functions

(void) - calcFrustumWidth:height:ll:ur:near:far:
(float) - minHeightAboveGlobe
 Return min/max valid heights above globe.
(float) - maxHeightAboveGlobe
(void) - setHeightAboveGlobe:
 Set the height above globe, taking constraints into account.
(void) - cancelAnimation
 Cancel any outstanding animation.
(void) - animate
 Renderer calls this every update.
(float) - calcZbufferRes
 Calculate the Z buffer resolution.
(float) - calcEarthZOffset
 Calculate the z offset to make the earth appear where we want it.
(Eigen::Affine3f) - calcModelMatrix
(Eigen::Vector3f) - currentUp
 Return where up (0,0,1) is after model rotation.
(Point3f) - pointUnproject:width:height:clip:
 From a screen point calculate the corresponding point in 3-space.
(bool) - pointOnSphereFromScreen:transform:frameSize:hit:
(CGPoint) - pointOnScreenFromSphere:transform:frameSize:
(Eigen::Quaternionf) - makeRotationToGeoCoord:keepNorthUp:

Static Public Member Functions

(Eigen::Vector3f) + prospectiveUp:
 Given a rotation, where would (0,0,1) wind up.
(WhirlyGlobeView *) + whirlyGlobeWithScene:frameInterval:

Properties

float fieldOfView
float imagePlaneSize
float nearPlane
float farPlane
float heightAboveGlobe
 The globe has a radius of 1.0 so 1.0 + heightAboveGlobe is the offset from the middle of the globe.
Eigen::Quaternion< float > rotQuat
 Quaternion used for rotation from origin state.
NSDate * lastChangedTime
 The last time the rotation was changed.
NSObject
< WhirlyGlobeAnimationDelegate > * 
delegate
 Used to update position based on time (or whatever other factor you like)
WhirlyGlobe::GlobeScenescene

Detailed Description

Globe View Parameters associated with viewing the globe.


Member Function Documentation

- (void) calcFrustumWidth: (unsigned int)  frameWidth
height: (unsigned int)  frameHeight
ll: (Point2f &)  ll
ur: (Point2f &)  ur
near: (float &)  near
far: (float &)  far 

Calculate the viewing frustum (which is also the image plane) Need the framebuffer size in pixels as input

- Eigen:

Generate the model view matrix for use by OpenGL Or calculation of our own

- Eigen: (const WhirlyGlobe::GeoCoord &)  worldLoc
keepNorthUp: (BOOL)  northUp 

Construct a rotation to the given location and return it. Doesn't actually do anything yet.

- (CGPoint) pointOnScreenFromSphere: (const Point3f &)  worldLoc
transform: (const Eigen::Affine3f *)  transform
frameSize: (const Point2f &)  frameSize 

From a world location (3D), figure out the projection to the screen Returns a point within the frame

- (bool) pointOnSphereFromScreen: (CGPoint)  pt
transform: (const Eigen::Affine3f *)  transform
frameSize: (const Point2f &)  frameSize
hit: (Point3f *)  hit 

Given a location on the screen and the screen size, figure out where we touched the sphere Returns true if we hit and where Returns false if not and the closest point on the sphere


The documentation for this class was generated from the following files: