12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- /*
- * ijksdl_ios.h
- *
- * Copyright (c) 2013 Bilibili
- * Copyright (c) 2013 Zhang Rui <bbcallen@gmail.com>
- *
- * This file is part of ijkPlayer.
- *
- * ijkPlayer is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * ijkPlayer is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with ijkPlayer; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- */
- //#include "ijksdl/ijksdl.h"
- //#include "ijksdl_aout_ios_audiounit.h"
- //#include "ijksdl_vout_ios_gles2.h"
- #import <UIKit/UIKit.h>
- #define SYSTEM_VERSION_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedSame)
- #define SYSTEM_VERSION_GREATER_THAN(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedDescending)
- #define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending)
- #define SYSTEM_VERSION_LESS_THAN(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedAscending)
- #define SYSTEM_VERSION_LESS_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedDescending)
- inline static BOOL isIOS9OrLater()
- {
- return SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"9.0");
- }
- inline static BOOL isIOS8OrLater()
- {
- return SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"8.0");
- }
- inline static BOOL isIOS7OrLater()
- {
- return SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"7.0");
- }
- inline static BOOL isIOS6OrLater()
- {
- return SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"6.0");
- }
|