SlideShare una empresa de Scribd logo
1 de 21
Descargar para leer sin conexión
Cross-platform development
             for
           iPhone
   Contributor: Tovchenko Taras
           (Doctor Set)
Plan

• What is cross-platform development
• Benefits & Expenses
• Implementation - 2 ways
• Use open source libraries
• A&Q
What does this mean “cross-platform”?


      1. GUI         2. Business logic
GUI porting is very bag applicable from
    iPhone to desktop platforms




                      -?
How we can distribute business logic?


 1. Base logic - memory, containers, etc.
 2. Logic of your application
 3. Graphic output (OpenGL, convertors)
 4. Audio output (OpenAL)
 5. Databases
What applications we can create full
cross-platform and what can be created
               particles?


1. (Full) Games - 60% at all iPhone applications
2. (Medium) Scientific applications which use graphic
   output - medical, engineering, etc.
3. (Not applicable) Applications based on iPhone GUI
Expenses
1. If you write 2 applications = you pay x2 $
2. Or you can write 1 application for 2 markets = x1.1 - x1.7 $
Several paths for attainment cross-platform




 • Porting existing code
 • Write new code than will be oriented to
    cross-platform
Porting
If you have already wrote project - use this method


                   Problems

1. Existing code wrote on language which not
compile on other platforms, often this is
Objective-C
2. On a project was used system depended api
(on iPhone this is POSIX)
3. GUI - which can’t be ported automatically to
other platforms
Solutions

•   For problem with code we can use some
    emulators of objective-c code - qobjc runtime,
    cocotron library.

•   For system api we can writes wrappers than will
    be defined on concrete platform.

•   GUI - for better case need redesign, for second
    case you can write some automatic engine for
    your dialogs.
Open Source libraries
•   For code porting (objc) currently we don’t have
    optimal solutions. Almost all libraries designed for
    Windows <-> Mac OS but not for iPhone.


               But we can use its for:
1. Learning and looking to its implementations

2. Improve this libraries for iPhone
Solutions for code porting


Lib name       License       Compiler
Cocotron        MIT            GCC
GNUStep         GPL            GCC
 qobjc      Author’s, GPL   Visual Studio
qobjc (quick)
             http://code.google.com/p/qobjc


   Scientific project, this is worked, tested runtime of
                  Objective-C language

Problem: this is only runtime lib, but for full functionality
                    need code parser
Objective-C
        @interface MyDecl : BaseClass <QMyProto2> {
            int _someInt;
            double _someDouble;
            float _someFloat;
        }

        - (float)calculateArea:(float)v0 :(float)v1 :(double)v2 :(float)v3 :(float)v4;
        - (void)dealloc; // in objective-c this method not need declare on header :)



                             Macro code on qobjc
        Q_BEGIN_CLASS(MyDecl, BaseClass)
            Q_INCLUDE_PROTOCOL_TO_CLASS(QMyProto2)
            Q_BEGIN_IVAR_LIST
                Q_DEF_IVAR(_someInt, i)
                Q_DEF_IVAR(_someDouble, d)
                Q_DEF_IVAR(_someFloat, f)
            Q_END
            Q_BEGIN_INSTANCE_METHOD_LIST
                Q_DEF_METHOD(calculateArea:, _calcAreaXY, +f+f+f+d+f+f)
                Q_DEF_METHOD(dealloc, _dealloc1, +v)
            Q_END_INSTANCE_METHOD_LIST
        Q_END_CLASS
New Code
       What benefits?
We can write code on already portable
language as - C++, and some scripting
     languages - LUA, PostScript
    For implementing system API uses
libraries (mostly C++) which wraps this
      work - example dCocoa, QT
Objective-C

-?       (speciality 2.0)
     is not cross-platform
dCocoa
     http://code.google.com/p/dcocoa

               LGPL license

Author’s library for cross-platform
implementation business logics for iPhone
and with possibility run or develop this logic
on Windows platform.
What give your dCocoa now?



1. Convenient Objective-C mechanisms
   emulation. This library writes on C++ and
   approximates to Foundation framework with
   almost all objc-runtime features.
2. Cross-platform between iPhone <-> Windows
1. Keep meta-information
2. Memory management (retain count,
   autorelease pools)
3. Containers (array, set, dictionary) in 2 form
   - for standard C++ types and dcocoa types
4. System dependent features (threads, TLS,
   timer, run-loop, etc)
5. Other helper classes (such as invocation,
   etc)
Objective-C                             dCocoa

@interface MyClass : NSObject {   class MyClass : public CL::dObject {
}                                 COCOA_CLASS_DECLARE(MyClass)
+ (void)method1;                  typedef CL::dObject _super;
- (void)method2;                  public:
                                      virtual MyClass* initWith(t a);
void func() {                         void method1(); // or virtual
  NSAutoreleasePool* pool =
[[NSAutorelease alloc] init];           METHOD_DECLARE(method2) // meta
                                  };
  id obj = [[MyClass alloc]       void func() {
initWith:5];                         _LocalPool

  [_someObject addTarget:obj        CL::dObject* obj =
selector:@selector(method2)];     MyClass::alloc()->initWith(5);
                                    _someObject->addTargetSelector(
[obj release];                          obj, dselector(method2));
[pool release];
}                                     CoRelease(obj);
                                  }
A&Q

Written by Taras Tovcheko, 2009/07/18
    e-mail: doctorset@gmail.com

Más contenido relacionado

La actualidad más candente

Review: Apitrace and Vogl
Review: Apitrace and VoglReview: Apitrace and Vogl
Review: Apitrace and VoglGao Yunzhong
 
Claire protorpc
Claire protorpcClaire protorpc
Claire protorpcFan Robbin
 
HKG15-207: Advanced Toolchain Usage Part 3
HKG15-207: Advanced Toolchain Usage Part 3HKG15-207: Advanced Toolchain Usage Part 3
HKG15-207: Advanced Toolchain Usage Part 3Linaro
 
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17LogeekNightUkraine
 
GCC Compiler as a Performance Testing tool for C programs
GCC Compiler as a Performance Testing tool for C programsGCC Compiler as a Performance Testing tool for C programs
GCC Compiler as a Performance Testing tool for C programsDaniel Ilunga
 
[COSCUP 2020] How to use llvm frontend library-libtooling
[COSCUP 2020] How to use llvm frontend library-libtooling[COSCUP 2020] How to use llvm frontend library-libtooling
[COSCUP 2020] How to use llvm frontend library-libtoolingDouglas Chen
 
Redis: Lua scripts - a primer and use cases
Redis: Lua scripts - a primer and use casesRedis: Lua scripts - a primer and use cases
Redis: Lua scripts - a primer and use casesRedis Labs
 
Introduction to the LLVM Compiler System
Introduction to the LLVM  Compiler SystemIntroduction to the LLVM  Compiler System
Introduction to the LLVM Compiler Systemzionsaint
 
3150 Chapter 2 Part 1
3150 Chapter 2 Part 13150 Chapter 2 Part 1
3150 Chapter 2 Part 1Mole Wong
 
Cross Platform App Development with C++
Cross Platform App Development with C++Cross Platform App Development with C++
Cross Platform App Development with C++Joan Puig Sanz
 
Hands on clang-format
Hands on clang-formatHands on clang-format
Hands on clang-formatKai Wolf
 
OOP in C - Before GObject (Chinese Version)
OOP in C - Before GObject (Chinese Version)OOP in C - Before GObject (Chinese Version)
OOP in C - Before GObject (Chinese Version)Kai-Feng Chou
 
LLVM Compiler - Link Time Optimization
LLVM Compiler - Link Time OptimizationLLVM Compiler - Link Time Optimization
LLVM Compiler - Link Time OptimizationVivek Pansara
 
Modern c++ (C++ 11/14)
Modern c++ (C++ 11/14)Modern c++ (C++ 11/14)
Modern c++ (C++ 11/14)Geeks Anonymes
 

La actualidad más candente (20)

Review: Apitrace and Vogl
Review: Apitrace and VoglReview: Apitrace and Vogl
Review: Apitrace and Vogl
 
Claire protorpc
Claire protorpcClaire protorpc
Claire protorpc
 
HKG15-207: Advanced Toolchain Usage Part 3
HKG15-207: Advanced Toolchain Usage Part 3HKG15-207: Advanced Toolchain Usage Part 3
HKG15-207: Advanced Toolchain Usage Part 3
 
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17
Vladymyr Bahrii Understanding polymorphism in C++ 16.11.17
 
GCC Compiler as a Performance Testing tool for C programs
GCC Compiler as a Performance Testing tool for C programsGCC Compiler as a Performance Testing tool for C programs
GCC Compiler as a Performance Testing tool for C programs
 
Gccgdb
GccgdbGccgdb
Gccgdb
 
Summary of C++17 features
Summary of C++17 featuresSummary of C++17 features
Summary of C++17 features
 
[COSCUP 2020] How to use llvm frontend library-libtooling
[COSCUP 2020] How to use llvm frontend library-libtooling[COSCUP 2020] How to use llvm frontend library-libtooling
[COSCUP 2020] How to use llvm frontend library-libtooling
 
Redis: Lua scripts - a primer and use cases
Redis: Lua scripts - a primer and use casesRedis: Lua scripts - a primer and use cases
Redis: Lua scripts - a primer and use cases
 
Introduction to the LLVM Compiler System
Introduction to the LLVM  Compiler SystemIntroduction to the LLVM  Compiler System
Introduction to the LLVM Compiler System
 
FTD JVM Internals
FTD JVM InternalsFTD JVM Internals
FTD JVM Internals
 
3150 Chapter 2 Part 1
3150 Chapter 2 Part 13150 Chapter 2 Part 1
3150 Chapter 2 Part 1
 
LLVM
LLVMLLVM
LLVM
 
Le langage rust
Le langage rustLe langage rust
Le langage rust
 
Cross Platform App Development with C++
Cross Platform App Development with C++Cross Platform App Development with C++
Cross Platform App Development with C++
 
C++ Presentation
C++ PresentationC++ Presentation
C++ Presentation
 
Hands on clang-format
Hands on clang-formatHands on clang-format
Hands on clang-format
 
OOP in C - Before GObject (Chinese Version)
OOP in C - Before GObject (Chinese Version)OOP in C - Before GObject (Chinese Version)
OOP in C - Before GObject (Chinese Version)
 
LLVM Compiler - Link Time Optimization
LLVM Compiler - Link Time OptimizationLLVM Compiler - Link Time Optimization
LLVM Compiler - Link Time Optimization
 
Modern c++ (C++ 11/14)
Modern c++ (C++ 11/14)Modern c++ (C++ 11/14)
Modern c++ (C++ 11/14)
 

Destacado

Принципы разработки ПО для iPhone с использованием акселерометра
Принципы разработки ПО для iPhone с использованием акселерометраПринципы разработки ПО для iPhone с использованием акселерометра
Принципы разработки ПО для iPhone с использованием акселерометраYandex
 
actsens - Introduction
actsens - Introductionactsens - Introduction
actsens - Introductionpayrow
 
Lunch And Learn July 2009
Lunch And Learn July 2009Lunch And Learn July 2009
Lunch And Learn July 2009jzaremba
 
iPhoneDevCamp Ukraine - вступление
iPhoneDevCamp Ukraine - вступлениеiPhoneDevCamp Ukraine - вступление
iPhoneDevCamp Ukraine - вступлениеYandex
 
Обзор фреймворков в iPhone SDK
Обзор фреймворков в iPhone SDKОбзор фреймворков в iPhone SDK
Обзор фреймворков в iPhone SDKYandex
 
Unity3d - простой путь к iPhone приложению
Unity3d - простой путь к iPhone приложениюUnity3d - простой путь к iPhone приложению
Unity3d - простой путь к iPhone приложениюYandex
 
iPhone Unit Testing (Google tool Box)
iPhone Unit Testing (Google tool Box)iPhone Unit Testing (Google tool Box)
iPhone Unit Testing (Google tool Box)Yandex
 
Push-уведомления для разработчика и пользователя
Push-уведомления для разработчика и пользователяPush-уведомления для разработчика и пользователя
Push-уведомления для разработчика и пользователяYandex
 
Red Flags Rule General
Red Flags Rule GeneralRed Flags Rule General
Red Flags Rule GeneralTeo Leonard
 
Thinking Digital Eğitim 1
Thinking Digital Eğitim 1Thinking Digital Eğitim 1
Thinking Digital Eğitim 1Eren Caner
 
Kanban at Yandex Images (Agile Days 2013)
Kanban at Yandex Images (Agile Days 2013)Kanban at Yandex Images (Agile Days 2013)
Kanban at Yandex Images (Agile Days 2013)Yandex
 
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)Yandex
 

Destacado (13)

Принципы разработки ПО для iPhone с использованием акселерометра
Принципы разработки ПО для iPhone с использованием акселерометраПринципы разработки ПО для iPhone с использованием акселерометра
Принципы разработки ПО для iPhone с использованием акселерометра
 
actsens - Introduction
actsens - Introductionactsens - Introduction
actsens - Introduction
 
Lunch And Learn July 2009
Lunch And Learn July 2009Lunch And Learn July 2009
Lunch And Learn July 2009
 
025 sds3213 28-toc
025 sds3213 28-toc025 sds3213 28-toc
025 sds3213 28-toc
 
iPhoneDevCamp Ukraine - вступление
iPhoneDevCamp Ukraine - вступлениеiPhoneDevCamp Ukraine - вступление
iPhoneDevCamp Ukraine - вступление
 
Обзор фреймворков в iPhone SDK
Обзор фреймворков в iPhone SDKОбзор фреймворков в iPhone SDK
Обзор фреймворков в iPhone SDK
 
Unity3d - простой путь к iPhone приложению
Unity3d - простой путь к iPhone приложениюUnity3d - простой путь к iPhone приложению
Unity3d - простой путь к iPhone приложению
 
iPhone Unit Testing (Google tool Box)
iPhone Unit Testing (Google tool Box)iPhone Unit Testing (Google tool Box)
iPhone Unit Testing (Google tool Box)
 
Push-уведомления для разработчика и пользователя
Push-уведомления для разработчика и пользователяPush-уведомления для разработчика и пользователя
Push-уведомления для разработчика и пользователя
 
Red Flags Rule General
Red Flags Rule GeneralRed Flags Rule General
Red Flags Rule General
 
Thinking Digital Eğitim 1
Thinking Digital Eğitim 1Thinking Digital Eğitim 1
Thinking Digital Eğitim 1
 
Kanban at Yandex Images (Agile Days 2013)
Kanban at Yandex Images (Agile Days 2013)Kanban at Yandex Images (Agile Days 2013)
Kanban at Yandex Images (Agile Days 2013)
 
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)
Хранение данных в iPhone. (FMDB, SQL-Persistence, CoreData)
 

Similar a Cross-platform iPhone Development Using Open Source Libraries

MattsonTutorialSC14.pptx
MattsonTutorialSC14.pptxMattsonTutorialSC14.pptx
MattsonTutorialSC14.pptxgopikahari7
 
Objective-C Runtime overview
Objective-C Runtime overviewObjective-C Runtime overview
Objective-C Runtime overviewFantageek
 
What Makes Objective C Dynamic?
What Makes Objective C Dynamic?What Makes Objective C Dynamic?
What Makes Objective C Dynamic?Kyle Oba
 
Code quality par Simone Civetta
Code quality par Simone CivettaCode quality par Simone Civetta
Code quality par Simone CivettaCocoaHeads France
 
Introduction to Software Development
Introduction to Software DevelopmentIntroduction to Software Development
Introduction to Software DevelopmentZeeshan MIrza
 
I assignmnt(oops)
I assignmnt(oops)I assignmnt(oops)
I assignmnt(oops)Jay Patel
 
Devoxx 2015 - Building the Internet of Things with Eclipse IoT
Devoxx 2015 - Building the Internet of Things with Eclipse IoTDevoxx 2015 - Building the Internet of Things with Eclipse IoT
Devoxx 2015 - Building the Internet of Things with Eclipse IoTBenjamin Cabé
 
Introduction-to-C-Part-1.pdf
Introduction-to-C-Part-1.pdfIntroduction-to-C-Part-1.pdf
Introduction-to-C-Part-1.pdfAnassElHousni
 
Unit 1 of c++ part 1 basic introduction
Unit 1 of c++ part 1 basic introductionUnit 1 of c++ part 1 basic introduction
Unit 1 of c++ part 1 basic introductionAKR Education
 
Introduction-to-C-Part-1.pptx
Introduction-to-C-Part-1.pptxIntroduction-to-C-Part-1.pptx
Introduction-to-C-Part-1.pptxNEHARAJPUT239591
 
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJ
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJIntroduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJ
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJmeharikiros2
 
C++ helps you to format the I/O operations like determining the number of dig...
C++ helps you to format the I/O operations like determining the number of dig...C++ helps you to format the I/O operations like determining the number of dig...
C++ helps you to format the I/O operations like determining the number of dig...bhargavi804095
 
Eclipse IoT Talk (Montreal JUG)
Eclipse IoT Talk (Montreal JUG)Eclipse IoT Talk (Montreal JUG)
Eclipse IoT Talk (Montreal JUG)Mike Milinkovich
 
Introduction-to-C-Part-1 (1).doc
Introduction-to-C-Part-1 (1).docIntroduction-to-C-Part-1 (1).doc
Introduction-to-C-Part-1 (1).docMayurWagh46
 
Java programming concept
Java programming conceptJava programming concept
Java programming conceptSanjay Gunjal
 
MobileConf 2021 Slides: Let's build macOS CLI Utilities using Swift
MobileConf 2021 Slides:  Let's build macOS CLI Utilities using SwiftMobileConf 2021 Slides:  Let's build macOS CLI Utilities using Swift
MobileConf 2021 Slides: Let's build macOS CLI Utilities using SwiftDiego Freniche Brito
 
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...bhargavi804095
 

Similar a Cross-platform iPhone Development Using Open Source Libraries (20)

MattsonTutorialSC14.pdf
MattsonTutorialSC14.pdfMattsonTutorialSC14.pdf
MattsonTutorialSC14.pdf
 
MattsonTutorialSC14.pptx
MattsonTutorialSC14.pptxMattsonTutorialSC14.pptx
MattsonTutorialSC14.pptx
 
Objective-C Runtime overview
Objective-C Runtime overviewObjective-C Runtime overview
Objective-C Runtime overview
 
What Makes Objective C Dynamic?
What Makes Objective C Dynamic?What Makes Objective C Dynamic?
What Makes Objective C Dynamic?
 
C++Basics2022.pptx
C++Basics2022.pptxC++Basics2022.pptx
C++Basics2022.pptx
 
Code quality par Simone Civetta
Code quality par Simone CivettaCode quality par Simone Civetta
Code quality par Simone Civetta
 
Introduction to Software Development
Introduction to Software DevelopmentIntroduction to Software Development
Introduction to Software Development
 
I assignmnt(oops)
I assignmnt(oops)I assignmnt(oops)
I assignmnt(oops)
 
Devoxx 2015 - Building the Internet of Things with Eclipse IoT
Devoxx 2015 - Building the Internet of Things with Eclipse IoTDevoxx 2015 - Building the Internet of Things with Eclipse IoT
Devoxx 2015 - Building the Internet of Things with Eclipse IoT
 
Introduction-to-C-Part-1.pdf
Introduction-to-C-Part-1.pdfIntroduction-to-C-Part-1.pdf
Introduction-to-C-Part-1.pdf
 
Unit 1 of c++ part 1 basic introduction
Unit 1 of c++ part 1 basic introductionUnit 1 of c++ part 1 basic introduction
Unit 1 of c++ part 1 basic introduction
 
Introduction-to-C-Part-1.pptx
Introduction-to-C-Part-1.pptxIntroduction-to-C-Part-1.pptx
Introduction-to-C-Part-1.pptx
 
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJ
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJIntroduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJ
Introduction-to-C-Part-1 JSAHSHAHSJAHSJAHSJHASJ
 
C++ helps you to format the I/O operations like determining the number of dig...
C++ helps you to format the I/O operations like determining the number of dig...C++ helps you to format the I/O operations like determining the number of dig...
C++ helps you to format the I/O operations like determining the number of dig...
 
Eclipse IoT Talk (Montreal JUG)
Eclipse IoT Talk (Montreal JUG)Eclipse IoT Talk (Montreal JUG)
Eclipse IoT Talk (Montreal JUG)
 
Introduction-to-C-Part-1 (1).doc
Introduction-to-C-Part-1 (1).docIntroduction-to-C-Part-1 (1).doc
Introduction-to-C-Part-1 (1).doc
 
Java programming concept
Java programming conceptJava programming concept
Java programming concept
 
MobileConf 2021 Slides: Let's build macOS CLI Utilities using Swift
MobileConf 2021 Slides:  Let's build macOS CLI Utilities using SwiftMobileConf 2021 Slides:  Let's build macOS CLI Utilities using Swift
MobileConf 2021 Slides: Let's build macOS CLI Utilities using Swift
 
Open Dayligth usando SDN-NFV
Open Dayligth usando SDN-NFVOpen Dayligth usando SDN-NFV
Open Dayligth usando SDN-NFV
 
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...
C++ was developed by Bjarne Stroustrup, as an extension to the C language. cp...
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 

Último (20)

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 

Cross-platform iPhone Development Using Open Source Libraries

  • 1. Cross-platform development for iPhone Contributor: Tovchenko Taras (Doctor Set)
  • 2. Plan • What is cross-platform development • Benefits & Expenses • Implementation - 2 ways • Use open source libraries • A&Q
  • 3. What does this mean “cross-platform”? 1. GUI 2. Business logic
  • 4. GUI porting is very bag applicable from iPhone to desktop platforms -?
  • 5. How we can distribute business logic? 1. Base logic - memory, containers, etc. 2. Logic of your application 3. Graphic output (OpenGL, convertors) 4. Audio output (OpenAL) 5. Databases
  • 6. What applications we can create full cross-platform and what can be created particles? 1. (Full) Games - 60% at all iPhone applications 2. (Medium) Scientific applications which use graphic output - medical, engineering, etc. 3. (Not applicable) Applications based on iPhone GUI
  • 7. Expenses 1. If you write 2 applications = you pay x2 $ 2. Or you can write 1 application for 2 markets = x1.1 - x1.7 $
  • 8. Several paths for attainment cross-platform • Porting existing code • Write new code than will be oriented to cross-platform
  • 9. Porting If you have already wrote project - use this method Problems 1. Existing code wrote on language which not compile on other platforms, often this is Objective-C 2. On a project was used system depended api (on iPhone this is POSIX) 3. GUI - which can’t be ported automatically to other platforms
  • 10. Solutions • For problem with code we can use some emulators of objective-c code - qobjc runtime, cocotron library. • For system api we can writes wrappers than will be defined on concrete platform. • GUI - for better case need redesign, for second case you can write some automatic engine for your dialogs.
  • 11. Open Source libraries • For code porting (objc) currently we don’t have optimal solutions. Almost all libraries designed for Windows <-> Mac OS but not for iPhone. But we can use its for: 1. Learning and looking to its implementations 2. Improve this libraries for iPhone
  • 12. Solutions for code porting Lib name License Compiler Cocotron MIT GCC GNUStep GPL GCC qobjc Author’s, GPL Visual Studio
  • 13. qobjc (quick) http://code.google.com/p/qobjc Scientific project, this is worked, tested runtime of Objective-C language Problem: this is only runtime lib, but for full functionality need code parser
  • 14. Objective-C @interface MyDecl : BaseClass <QMyProto2> { int _someInt; double _someDouble; float _someFloat; } - (float)calculateArea:(float)v0 :(float)v1 :(double)v2 :(float)v3 :(float)v4; - (void)dealloc; // in objective-c this method not need declare on header :) Macro code on qobjc Q_BEGIN_CLASS(MyDecl, BaseClass)         Q_INCLUDE_PROTOCOL_TO_CLASS(QMyProto2)         Q_BEGIN_IVAR_LIST             Q_DEF_IVAR(_someInt, i)             Q_DEF_IVAR(_someDouble, d)             Q_DEF_IVAR(_someFloat, f)         Q_END         Q_BEGIN_INSTANCE_METHOD_LIST             Q_DEF_METHOD(calculateArea:, _calcAreaXY, +f+f+f+d+f+f)             Q_DEF_METHOD(dealloc, _dealloc1, +v)         Q_END_INSTANCE_METHOD_LIST     Q_END_CLASS
  • 15. New Code What benefits? We can write code on already portable language as - C++, and some scripting languages - LUA, PostScript For implementing system API uses libraries (mostly C++) which wraps this work - example dCocoa, QT
  • 16. Objective-C -? (speciality 2.0) is not cross-platform
  • 17. dCocoa http://code.google.com/p/dcocoa LGPL license Author’s library for cross-platform implementation business logics for iPhone and with possibility run or develop this logic on Windows platform.
  • 18. What give your dCocoa now? 1. Convenient Objective-C mechanisms emulation. This library writes on C++ and approximates to Foundation framework with almost all objc-runtime features. 2. Cross-platform between iPhone <-> Windows
  • 19. 1. Keep meta-information 2. Memory management (retain count, autorelease pools) 3. Containers (array, set, dictionary) in 2 form - for standard C++ types and dcocoa types 4. System dependent features (threads, TLS, timer, run-loop, etc) 5. Other helper classes (such as invocation, etc)
  • 20. Objective-C dCocoa @interface MyClass : NSObject { class MyClass : public CL::dObject { } COCOA_CLASS_DECLARE(MyClass) + (void)method1; typedef CL::dObject _super; - (void)method2; public: virtual MyClass* initWith(t a); void func() { void method1(); // or virtual NSAutoreleasePool* pool = [[NSAutorelease alloc] init]; METHOD_DECLARE(method2) // meta }; id obj = [[MyClass alloc] void func() { initWith:5]; _LocalPool [_someObject addTarget:obj CL::dObject* obj = selector:@selector(method2)]; MyClass::alloc()->initWith(5); _someObject->addTargetSelector( [obj release]; obj, dselector(method2)); [pool release]; } CoRelease(obj); }
  • 21. A&Q Written by Taras Tovcheko, 2009/07/18 e-mail: doctorset@gmail.com