You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/cross-platform/build-an-opengl-es-application-on-android-and-ios.md
+7-7Lines changed: 7 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
-
title: "Build an OpenGL ES Application on Android and iOS | Microsoft Docs"
2
+
title: "Build an OpenGL ES application on Android and iOS | Microsoft Docs"
3
3
ms.custom: ""
4
-
ms.date: "09/17/2019"
4
+
ms.date: "10/09/2019"
5
5
ms.technology: vs-ide-mobile
6
6
ms.topic: "conceptual"
7
7
dev_langs:
@@ -19,13 +19,13 @@ You can create Visual Studio solutions and projects for iOS apps and Android app
19
19
20
20
## Requirements
21
21
22
-
Before you can create an OpenGL ES app for iOS and Android, make sure you've met all system requirements. If you haven't already, install the Mobile Development with C++ workload in the Visual Studio Installer. To build for iOS, include the optional C++ iOS development tools. To build for Android, install the C++ Android development tools and the required third-party tools: Android NDK, Apache Ant, and Google Android Emulator. For better emulator performance on Intel platforms, we recommend you also install the Intel Hardware Accelerated Execution Manager (HAXM). Next, configure Intel HAXM and the Android Emulator to run on your system. For more information and detailed instructions, see [Install Visual C++ for cross-platform mobile development](../cross-platform/install-visual-cpp-for-cross-platform-mobile-development.md).
22
+
Before you can create an OpenGL ES app for iOS and Android, make sure you've met all system requirements. If you haven't already, install the Mobile Development with C++ workload in the Visual Studio Installer. To get the OpenGL ES templates, and to build for iOS, include the optional C++ iOS development tools. To build for Android, install the C++ Android development tools and the required third-party tools: Android NDK, Apache Ant, and Google Android Emulator. For better emulator performance on Intel platforms, we recommend you also install the Intel Hardware Accelerated Execution Manager (HAXM). Next, configure Intel HAXM and the Android Emulator to run on your system. For more information and detailed instructions, see [Install cross-platform mobile development with C++](../cross-platform/install-visual-cpp-for-cross-platform-mobile-development.md).
23
23
24
24
To build and test the iOS app, you'll need a Mac computer, set up according to the installation instructions. For more information about how to set up for iOS development, see [Install and configure tools to build using iOS](../cross-platform/install-and-configure-tools-to-build-using-ios.md).
25
25
26
26
## Create a new OpenGLES Application project
27
27
28
-
In this tutorial, you first create a new OpenGL ES Application project. and then build and run the default app in the Visual Studio Emulator for Android. Next you build the app for iOS and run the app on an iOS device.
28
+
In this tutorial, you first create a new OpenGL ES Application project. and then build and run the default app in an Android emulator. Next you build the app for iOS and run the app on an iOS device.
29
29
30
30
::: moniker range="vs-2017"
31
31
@@ -69,7 +69,7 @@ The solution has two projects to build the apps for the Android and iOS platform
69
69
70
70
-`MyOpenGLESApp.Android.Packaging` creates the *.apk* file for deployment on an Android device or emulator. This file contains the resources and AndroidManifest.xml file where you set manifest properties. It also contains the *build.xml* file that controls the Ant build process. It's set as the startup project by default, so that it can be deployed and run directly from Visual Studio.
71
71
72
-
-**MyOpenGLESApp.iOS.Application** contains the resources and Objective-C glue code to create an iOS app that links to the C++ static library code in `MyOpenGLESApp.iOS.StaticLibrary`. This project creates a build package that is transferred to your Mac by Visual Studio and the remote agent. When you build this project, Visual Studio sends the files and commands to build and deploy your app on the Mac.
72
+
-`MyOpenGLESApp.iOS.Application` contains the resources and Objective-C glue code to create an iOS app that links to the C++ static library code in `MyOpenGLESApp.iOS.StaticLibrary`. This project creates a build package that is transferred to your Mac by Visual Studio and the remote agent. When you build this project, Visual Studio sends the files and commands to build and deploy your app on the Mac.
73
73
74
74
## Build and run the Android app
75
75
@@ -97,7 +97,7 @@ The solution created by the template sets the Android app as the default project
97
97
98
98
If you have installed other emulators or connected an Android device, you can choose them in the deployment target drop-down list. To run the app, the built Solution Platform must match the platform of the target device.
99
99
100
-
1. Press F5 to start debugging, or Shift+F5 to start without debugging.
100
+
1. Press **F5** to start debugging, or **Shift**+**F5** to start without debugging.
101
101
102
102
Visual Studio starts the emulator, which takes several seconds to load and deploy your code. Here's how the app appears in the emulator:
103
103
@@ -121,7 +121,7 @@ To deploy an iOS app to an iOS device, you must also set up automatic signing on
121
121
122
122
### To set up automatic signing on Xcode
123
123
124
-
1. If you haven't already, install [Xcode](https://developer.apple.com/xcode/downloads/) version 10.2.1 or later on your Mac.
124
+
1. If you haven't already, install [Xcode](https://developer.apple.com/xcode/) on your Mac.
title: "Create an Android Native Activity App | Microsoft Docs"
3
3
ms.custom: ""
4
-
ms.date: "11/04/2016"
4
+
ms.date: "10/17/2019"
5
5
ms.technology: vs-ide-mobile
6
6
ms.topic: "conceptual"
7
7
dev_langs:
@@ -15,37 +15,53 @@ ms.workload:
15
15
---
16
16
# Create an Android Native Activity App
17
17
18
-
When you install the Visual C++ for Cross-Platform Mobile Development option, Visual Studio 2015 can be used to create fully functional Android Native Activity apps. The Android Native Development Kit (NDK) is a toolset that allows you to implement the majority of your Android app using pure C/C++ code. Some Java JNI code acts as glue to allow your C/C++ code to interact with Android. The Android NDK introduced the ability to create Native Activity apps with Android API Level 9. Native Activity code is popular for creating gaming and graphic intensive apps that use Unreal Engine or OpenGL. This topic will guide you through creation of a simple Native Activity app that uses OpenGL. Additional topics walk through the developer lifecycle of editing, building, debugging and deploying Native Activity code.
18
+
When you install the cross-platform **Mobile development with C++** workload, Visual Studio can be used to create fully functional Android Native Activity apps. The Android Native Development Kit (NDK) is a toolset that allows you to implement the majority of your Android app using pure C/C++ code. Some Java JNI code acts as glue to allow your C/C++ code to interact with Android. The Android NDK introduced the ability to create Native Activity apps with Android API Level 9. Native Activity code is popular for creating gaming and graphic intensive apps that use Unreal Engine or OpenGL. This topic will guide you through creation of a simple Native Activity app that uses OpenGL. Additional topics walk through the developer lifecycle of editing, building, debugging and deploying Native Activity code.
19
19
20
20
## Requirements
21
21
22
-
Before you can create an Android Native Activity app, you must make sure you've met all system requirements, and installed the Visual C++ Mobile Development option in Visual Studio 2015. For more information, see [Install Visual C++ for Cross-Platform Mobile Development](../cross-platform/install-visual-cpp-for-cross-platform-mobile-development.md). Make sure that the required third-party tools and SDKs are included in the installation, and that the Microsoft Visual Studio Emulator for Android is installed.
22
+
Before you can create an Android Native Activity app, you must make sure you've met all system requirements, and installed the **Mobile development with C++** workload in Visual Studio. For more information, see [Install cross-platform mobile development with C++](../cross-platform/install-visual-cpp-for-cross-platform-mobile-development.md). Make sure that the required third-party tools and SDKs are included in the installation, and that an Android emulator is installed.
23
23
24
24
## Create a new Native Activity project
25
25
26
-
In this tutorial, you'll first create a new Android Native Activity project and then build and run the default app in the Visual Studio Emulator for Android.
26
+
In this tutorial, you'll first create a new Android Native Activity project and then build and run the default app in an Android emulator.
27
+
28
+
::: moniker range="vs-2017"
27
29
28
30
1. In Visual Studio, choose **File** > **New** > **Project**.
29
31
30
-
2. In the **New Project** dialog box, under **Templates**, choose **Visual C++** > **Cross Platform**, and then choose the **Native-Activity Application (Android)** template.
32
+
1. In the **New Project** dialog box, under **Templates**, choose **Visual C++** > **Cross Platform**, and then choose the **Native-Activity Application (Android)** template.
33
+
34
+
1. Give the app a name like *MyAndroidApp*, and then choose **OK**.
35
+
36
+

37
+
38
+
Visual Studio creates the new solution and opens Solution Explorer.
39
+
40
+

41
+
42
+
::: moniker-end
43
+
44
+
::: moniker range=">=vs-2019"
45
+
46
+
1. In Visual Studio, choose **File** > **New** > **Project**.
31
47
32
-
3. Give the app a name like `MyAndroidApp`, and then choose **OK**.
48
+
1. In the **Create a new project** dialog box, select the **Native-Activity Application (Android)** template, and then choose **Next**.
33
49
34
-

50
+
1. In the **Configure your new project** dialog box, enter a name like *MyAndroidApp* in **Project name**, and then choose **Create**.
35
51
36
-
Visual Studio creates the new solution and opens Solution Explorer.
52
+
Visual Studio creates the new solution and opens Solution Explorer.
37
53
38
-

54
+
::: moniker-end
39
55
40
-
The new Android Native Activity app solution includes two projects:
56
+
The new Android Native Activity app solution includes two projects:
41
57
42
58
-`MyAndroidApp.NativeActivity` contains the references and glue code for your app to run as a Native Activity on Android. The implementation of the entry points from the glue code are in *main.cpp*. Precompiled headers are in *pch.h*. This Native Activity app project is compiled into a shared library *.so* file which is picked up by the Packaging project.
43
59
44
60
-`MyAndroidApp.Packaging` creates the *.apk* file for deployment on an Android device or emulator. This contains the resources and *AndroidManifest.xml* file where you set manifest properties. It also contains the *build.xml* file that controls the Ant build process. It's set as the startup project by default, so that it can be deployed and run directly from Visual Studio.
45
61
46
62
## Build and run the default Android Native Activity app
47
63
48
-
Build and run the app generated by the template to verify your installation and setup. For this initial test, run the app on one of the device profiles installed by the Visual Studio Emulator for Android. If you prefer to test your app on another target, you can load the target emulator or connect the device to your computer.
64
+
Build and run the app generated by the template to verify your installation and setup. For this initial test, run the app on one of the device profiles installed by the Android emulator. If you prefer to test your app on another target, you can load the target emulator or connect the device to your computer.
49
65
50
66
## To build and run the default Native Activity app
51
67
@@ -55,22 +71,22 @@ Build and run the app generated by the template to verify your installation and
55
71
56
72
If the **Solution Platforms** list isn't showing, choose **Solution Platforms** from the **Add/Remove Buttons** list, and then choose your platform.
57
73
58
-
2. On the menu bar, choose **Build** > **Build Solution**.
74
+
1. On the menu bar, choose **Build** > **Build Solution**.
59
75
60
76
The Output window displays the output of the build process for the two projects in the solution.
61
77
62
-
3. Choose one of the VS Emulator Android Phone (x86) profiles as your deployment target.
78
+
1. Choose one of the Android emulator profiles as your deployment target.
63
79
64
80
If you have installed other emulators or connected an Android device, you can choose them in the deployment target dropdown list.
65
81
66
-
4. Press **F5** to start debugging, or Shift+F5 to start without debugging.
82
+
1. Press **F5** to start debugging, or **Shift**+**F5** to start without debugging.
67
83
68
-
Here's what the default app looks like in the Visual Studio emulator for Android.
84
+
Here's what the default app looks like in an Android emulator.
69
85
70
-

86
+

71
87
72
-
Visual Studio starts the emulator, which takes a few seconds to load and deploy your code. Once your app has started, you can set breakpoints and use the debugger to step through code, examine locals, and watch values.
88
+
Visual Studio starts the emulator, which takes a few seconds to load and deploy your code. Once your app has started, you can set breakpoints and use the debugger to step through code, examine locals, and watch values.
73
89
74
-
5. Press **Shift**+**F5** to stop debugging.
90
+
1. Press **Shift**+**F5** to stop debugging.
75
91
76
-
The emulator is a separate process that continues to run. You can edit, compile, and deploy your code multiple times to the same emulator.
92
+
The emulator is a separate process that continues to run. You can edit, compile, and deploy your code multiple times to the same emulator.
Copy file name to clipboardExpand all lines: docs/cross-platform/cross-platform-mobile-development-examples.md
+6-5Lines changed: 6 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
-
title: "Cross-Platform Mobile Development Examples | Microsoft Docs"
2
+
title: "Cross-platform mobile development examples | Microsoft Docs"
3
3
ms.custom: ""
4
-
ms.date: "11/04/2016"
4
+
ms.date: "10/17/2019"
5
5
ms.technology: vs-ide-mobile
6
6
ms.topic: "conceptual"
7
7
dev_langs:
@@ -14,7 +14,8 @@ ms.workload:
14
14
- "xplat-cplusplus"
15
15
---
16
16
# Cross-platform mobile development examples
17
-
Several of the templates installed by Visual C++ for Cross-Platform Mobile Development generate complete examples that you can use to learn from. Additionally, the Windows Dev Center has several example applications that you can download and try out in Visual Studio.
17
+
18
+
Several of the templates installed by the **Mobile development with C++** workload generate complete examples that you can use to learn from. Additionally, the Windows Dev Center has several example applications that you can download and try out in Visual Studio.
This sample is a port of the Android NDK TwoLibs sample. It uses both a dynamically loaded shared library, and a static C++ Android native library, that implements a method called from a Java Native Interface app. This sample is a good starting point for developers to understand how to use static/dynamic shared libraries to build an end-to-end JNI Android application with Visual Studio 2015.
34
+
This sample is a port of the Android NDK TwoLibs sample. It uses both a dynamically loaded shared library, and a static C++ Android native library, that implements a method called from a Java Native Interface app. This sample is a good starting point for developers to understand how to use static/dynamic shared libraries to build an end-to-end JNI Android application with Visual Studio.
34
35
35
36
-[Tea Pot Android Application Sample](https://code.msdn.microsoft.com/Tea-Pot-Android-Application-e7c05d73)
36
37
@@ -42,7 +43,7 @@ Several of the templates installed by Visual C++ for Cross-Platform Mobile Devel
This sample is a port of the Android NDK test-libstdc++ sample, specifically for use with Visual Studio 2015. This sample is a good starting point for developers to understand how to use the Standard Library.
46
+
This sample is a port of the Android NDK test-libstdc++ sample, specifically for use with Visual Studio. This sample is a good starting point for developers to understand how to use the Standard Library.
46
47
47
48
To open one of the examples in Visual Studio, download the zip file and open the **Properties** page of the downloaded file in Explorer. Choose the **Unblock** button then choose **OK**. Extract the contents of the zip file to a convenient location, then open the C++ folder in the extracted sample and open the solution file.
0 commit comments