From 3e7c59b231284b5f9da5f9d67c70949ec82f00cc Mon Sep 17 00:00:00 2001 From: Christophe Geuzaine <cgeuzaine@ulg.ac.be> Date: Wed, 30 Nov 2016 12:26:42 +0000 Subject: [PATCH] pp --- contrib/mobile/drawContext.cpp | 10 +++++----- contrib/mobile/iOS/Onelab/ModelViewController.mm | 12 ++++++++---- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/contrib/mobile/drawContext.cpp b/contrib/mobile/drawContext.cpp index 3968441e6d..f84ba5562d 100644 --- a/contrib/mobile/drawContext.cpp +++ b/contrib/mobile/drawContext.cpp @@ -242,9 +242,9 @@ void drawArray(VertexArray *va, GLint type, bool useColorArray, bool useNormalAr { if(!va) return; glEnable(GL_RESCALE_NORMAL); - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - glEnable(GL_BLEND); - glShadeModel(GL_SMOOTH); + glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + glEnable(GL_BLEND); + glShadeModel(GL_SMOOTH); glVertexPointer(3, GL_FLOAT, 0, va->getVertexArray()); glEnableClientState(GL_VERTEX_ARRAY); if(useNormalArray){ @@ -259,8 +259,8 @@ void drawArray(VertexArray *va, GLint type, bool useColorArray, bool useNormalAr glDisableClientState(GL_VERTEX_ARRAY); glDisableClientState(GL_NORMAL_ARRAY); glDisableClientState(GL_COLOR_ARRAY); - glDisable(GL_BLEND); - glDisable(GL_RESCALE_NORMAL); + glDisable(GL_BLEND); + glDisable(GL_RESCALE_NORMAL); } void drawVector(double x, double y, double z, double dx, double dy, double dz) diff --git a/contrib/mobile/iOS/Onelab/ModelViewController.mm b/contrib/mobile/iOS/Onelab/ModelViewController.mm index 3b5f570293..f3475c37de 100644 --- a/contrib/mobile/iOS/Onelab/ModelViewController.mm +++ b/contrib/mobile/iOS/Onelab/ModelViewController.mm @@ -301,7 +301,8 @@ #pragma mark - Split view --(BOOL)splitViewController:(UISplitViewController *)svc shouldHideViewController:(UIViewController *)vc inOrientation:(UIInterfaceOrientation)orientation +-(BOOL)splitViewController:(UISplitViewController *)svc shouldHideViewController:(UIViewController *)vc + inOrientation:(UIInterfaceOrientation)orientation { return NO; } @@ -345,12 +346,15 @@ void messageFromCpp (void *self, std::string level, std::string msg) [_progressLabel setHidden:!_progressLabel.hidden]; } -void getBitmap(void *self, const char *text, int textsize, unsigned char **map, int *height, int *width, int *realWidth) +void getBitmap(void *self, const char *text, int textsize, unsigned char **map, + int *height, int *width, int *realWidth) { - [(__bridge id)self getBitmapFromStringObjC:text withTextSize:textsize inMap:map inHeight:height inWidth:width inRealWidth:realWidth]; + [(__bridge id)self getBitmapFromStringObjC:text withTextSize:textsize inMap:map + inHeight:height inWidth:width inRealWidth:realWidth]; } --(void) getBitmapFromStringObjC:(const char *)text withTextSize:(int)textsize inMap:(unsigned char **)map inHeight:(int *)height inWidth:(int *)width inRealWidth:(int *) realWidth +-(void) getBitmapFromStringObjC:(const char *)text withTextSize:(int)textsize inMap:(unsigned char **)map + inHeight:(int *)height inWidth:(int *)width inRealWidth:(int *) realWidth { UILabel *lbl = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, 1024, 7*textsize/6)]; lbl.font = [UIFont systemFontOfSize:textsize]; -- GitLab