Fix a number of issues with iOS build.
Set pointer to root view in window (for SampleApp) Set up the correct function pointer for GL multisampling Remove use of SkBitmap::setConfig() Remove incomplete iOS implementation of SkFILE (use SkOSFile for now) R=caryclark@google.com, reed@google.com, bsalomon@google.com, tfarina@chromium.org Author: jvanverth@google.com Review URL: https://codereview.chromium.org/322403007
This commit is contained in:
parent
72abfc2b4e
commit
66c9582d1b
@ -7,6 +7,9 @@
|
|||||||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
||||||
[window addSubview:[splitViewController view]];
|
[window addSubview:[splitViewController view]];
|
||||||
[window makeKeyAndVisible];
|
[window makeKeyAndVisible];
|
||||||
|
|
||||||
|
self.window.rootViewController = splitViewController;
|
||||||
|
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,6 +6,9 @@
|
|||||||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
|
||||||
[window addSubview:fRoot.view];
|
[window addSubview:fRoot.view];
|
||||||
[window makeKeyAndVisible];
|
[window makeKeyAndVisible];
|
||||||
|
|
||||||
|
self.window.rootViewController = fRoot;
|
||||||
|
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -236,7 +236,8 @@
|
|||||||
'../src/views/ios/SkOSWindow_iOS.mm',
|
'../src/views/ios/SkOSWindow_iOS.mm',
|
||||||
'../src/utils/ios/SkImageDecoder_iOS.mm',
|
'../src/utils/ios/SkImageDecoder_iOS.mm',
|
||||||
'../src/utils/ios/SkStream_NSData.mm',
|
'../src/utils/ios/SkStream_NSData.mm',
|
||||||
'../src/utils/ios/SkOSFile_iOS.mm',
|
# Not fully implemented yet
|
||||||
|
# '../src/utils/ios/SkOSFile_iOS.mm',
|
||||||
|
|
||||||
'../src/utils/mac/SkCreateCGImageRef.cpp',
|
'../src/utils/mac/SkCreateCGImageRef.cpp',
|
||||||
'../experimental/iOSSampleApp/SkiOSSampleApp-Debug.xcconfig',
|
'../experimental/iOSSampleApp/SkiOSSampleApp-Debug.xcconfig',
|
||||||
|
@ -139,7 +139,7 @@ const GrGLInterface* GrGLCreateNativeInterface() {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if GL_APPLE_framebuffer_multisample
|
#if GL_APPLE_framebuffer_multisample
|
||||||
functions->fRenderbufferStorageMultisample = glRenderbufferStorageMultisampleAPPLE;
|
functions->fRenderbufferStorageMultisampleES2APPLE = glRenderbufferStorageMultisampleAPPLE;
|
||||||
functions->fResolveMultisampleFramebuffer = glResolveMultisampleFramebufferAPPLE;
|
functions->fResolveMultisampleFramebuffer = glResolveMultisampleFramebufferAPPLE;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -29,7 +29,8 @@ bool SkImageDecoder_iOS::onDecode(SkStream* stream, SkBitmap* bm, Mode mode) {
|
|||||||
|
|
||||||
const int width = uimage.size.width;
|
const int width = uimage.size.width;
|
||||||
const int height = uimage.size.height;
|
const int height = uimage.size.height;
|
||||||
bm->setConfig(SkBitmap::kARGB_8888_Config, width, height);
|
SkColorType ct = SkBitmapConfigToColorType(SkBitmap::kARGB_8888_Config);
|
||||||
|
bm->setInfo(SkImageInfo::Make(width, height, ct, kPremul_SkAlphaType), 0);
|
||||||
if (SkImageDecoder::kDecodeBounds_Mode == mode) {
|
if (SkImageDecoder::kDecodeBounds_Mode == mode) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user