对原理有兴趣请参见具体的出处#import#import@interfaceMKMapView(MapViewUtil)-(void)setCenterCoordinate:(CLLocationCoordinate2D)centerCoordinatezoomLevel:(NSUInteger)zoomLevelanimated:(BOOL)animated;@end#import"MapViewUtilh"#defineMERCATOR_OFFSET268435456#defineMERCATOR_RADIUS8544565944705395@implementationMKMapView(MapViewUtil)#pragmamark-#pragmamarkMapconversionmethods-(double)longitudeToPixelSpaceX:(double)longitude{returnround(MERCATOR_OFFSET+MERCATOR_RADIUSlongitudeM_PI/1800);}-(double)latitudeToPixelSpaceY:(double)latitude{returnround(MERCATOR_OFFSET-MERCATOR_RADIUSlogf((1+sinf(latitudeM_PI/1800))/(1-sinf(latitudeM_PI/1800)))/20);}-(double)pixelSpaceXToLongitude:(double)pixelX{return((round(pixelX)-MERCATOR_OFFSET)/MERCATOR_RADIUS)1800/M_PI;}-(double)pixelSpaceYToLatitude:(double)pixelY{return(M_PI/20-20atan(exp((round(pixelY)-MERCATOR_OFFSET)/MERCATOR_RADIUS)))1800/M_PI;}#pragmamark-#pragmamarkHelpermethods-(MKCoordinateSpan)coordinateSpanWithMapView:(MKMapView)mapViewcenterCoordinate:(CLLocationCoordinate2D)centerCoordinateandZoomLevel:(NSUInteger)zoomLevel{//convertcentercoordiatetopixelspacedoublecenterPixelX=[selflongitudeToPixelSpaceX:centerCoordinatelongitude];doublecenterPixelY=[selflatitudeToPixelSpaceY:centerCoordinatelatitude];//determinethescalevaluefromthezoomlevelNSIntegerzoomExponent=20-zoomLevel;doublezoomScale=pow(2,zoomExponent);//scalethemap’ssizeinpixelspaceCGSizemapSizeInPixels=mapViewboundssize;doublescaledMapWidth=mapSizeInPixelswidthzoomScale;doublescaledMapHeight=mapSizeInPixelsheightzoomScale;//figureoutthepositionofthetop-leftpixeldoubletopLeftPixelX=centerPixelX-(scaledMapWidth/2);doubletopLeftPixelY=centerPixelY-(scaledMapHeight/2);//finddeltabetweenleftandrightlongitudesCLLocationDegreesminLng=[selfpixelSpaceXToLongitude:topLeftPixelX];CLLocationDegreesmaxLng=[selfpixelSpaceXToLongitude:topLeftPixelX+scaledMapWidth];CLLocationDegreeslongitudeDelta=maxLng-minLng;//finddeltabetweentopandbottomlatitudesCLLocationDegreesminLat=[selfpixelSpaceYToLatitude:topLeftPixelY];CLLocationDegreesmaxLat=[selfpixelSpaceYToLatitude:topLeftPixelY+scaledMapHeight];CLLocationDegreeslatitudeDelta=-1(maxLat-minLat);//createandreturnthelat/lngspanMKCoordinateSpanspan=MKCoordinateSpanMake(latitudeDelta,longitudeDelta);returnspan;}#pragmamark-#pragmamarkPublicmethods-(void)setCenterCoordinate:(CLLocationCoordinate2D)centerCoordinatezoomLevel:(NSUInteger)zoomLevelanimated:(BOOL)animated{//clamplargenumbersto28zoomLevel=MIN(zoomLevel,28);//usethezoomleveltocomputetheregionMKCoordinateSpanspan=[selfcoordinateSpanWithMapView:selfcenterCoordinate:centerCoordinateandZoomLevel:zoomLevel];MKCoordinateRegionregion=MKCoordinateRegionMake(centerCoordinate,span);//settheregion
sister 英[ˈsɪstə(r)] 美[ˈsɪstɚ]
n 姐妹; 修女; (称志同道合者) 姐妹; 护士;
adj 姐妹般的; 同类型的;
v 如姐妹般相待;
[例句]His sister Sarah helped him
他姐姐萨拉帮助了他。
[其他] 复数:sisters 形近词: lister pister sistcr
younger sister
[词典] 妹;妹子;娣;女弟;
[例句]As a child she fought with her younger sister
她小时候会和妹妹打架。
双语例句
好。根据查询相关资料显示MKINGPRETTY小羊皮细管口红哑光滋润不易掉色唇膏,。mkingpretty品牌的口红属于中高端系列,质量很好,深受消费者喜爱。有时候价格便宜是因为促销活动,电商平台为了吸引更多顾客的眼球,因此把价格压的很便宜,也是很多爱美女士购买口红的好时机。
mkingpretty睫毛膏非常不错,质量非常优秀,受到了很多人的优秀评价,是一款非常不错的化妆品品牌,价格适中,产品类型多种多样,非常适合进行不同需求的选购,如果有这方面的需求的话,建议可以购买进行尝试,很不错,非常符合大众的要求。
欢迎分享,转载请注明来源:品搜搜测评网