<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Cenk Türker on Medium]]></title>
        <description><![CDATA[Stories by Cenk Türker on Medium]]></description>
        <link>https://medium.com/@cenkturker07?source=rss-22aec095ced2------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*h2o5qDUcnBakSs-9.jpg</url>
            <title>Stories by Cenk Türker on Medium</title>
            <link>https://medium.com/@cenkturker07?source=rss-22aec095ced2------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 12:15:37 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@cenkturker07/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Introduction to HMS Accelerate Kit, Importance of Multithreading and Application on Project]]></title>
            <link>https://medium.com/huawei-developers/introduction-to-hms-accelerate-kit-importance-of-multithreading-and-application-on-project-a6c7ddc5507a?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/a6c7ddc5507a</guid>
            <category><![CDATA[hms]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[accelerate-kit]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[huawei-mobile-service]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Fri, 25 Jun 2021 08:33:31 GMT</pubDate>
            <atom:updated>2021-06-25T08:33:31.263Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qLPiOorVOeW-Z1h_dBtvlw.png" /></figure><p>Hello Everyone, In this article, I’m going to tell you what the accelerate kit is, for what purposes it can be used ,its advantages ,key capabilities, integration period and how to demonstrate on our project.</p><h3>Overview</h3><p>HUAWEI Accelerate Kit provides multi-thread acceleration and computing acceleration solutions to facilitate better application performance. Today, It is used in many areas of developing technology. In addition, accelerate kit is a novelty with coming released to <strong>HMS Core version 5.0</strong> .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KJs5JmmInIx3XfZRLiBfSw.png" /><figcaption>HMS Core 5.0</figcaption></figure><h4><strong>New Features with version 5.0.0.300</strong></h4><p>We see the <strong>“multithreading-library”</strong> function added to provide a multithreaded programming framework at the native layer for streamlined application performance.</p><h3>Multithreading-library Concept</h3><p>If we ask what this <strong>“multithread-library”</strong> does.. It provides the necessary APIs for queuing and executing your tasks on multi-core hardware in order to use the resources your system offers you in the most efficient way. Based on the <strong>“Queue”</strong> logic, it works with the first-in-first-out <strong>(FIFO)</strong> method.</p><h3>What is Multithreading ?</h3><p>Multithreading is the basics programming principle for multiple software languages ​​and enables multiple jobs to be done in a program at the same time.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*ckEihMg7ZxrzQsL89JGGLA.jpeg" /><figcaption>Multi-Threading picture</figcaption></figure><p>In other words, while a piece of code is performing a process, it means that another piece of code also works in parallel with it. Programs that do not have a multithread structure describe a thread named main thread.</p><h3>Introduction to Accelerate Kit</h3><p>HUAWEI Accelerate Kit provides the <strong>multi-thread</strong> acceleration capability that efficiently improves concurrent execution of multiple threads. It is located above the kernel in the OS and opened to developers as a set of C language APIs.</p><h4>Key Capabilities of Accelerate Kit</h4><p>Accelerate Kit ensure that <strong>advanced multi-thread</strong> programming and computing acceleration solutions to help many developers to analyze thread overloading and application performance problems easily.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/450/1*LlwyGNv6DVqI4u7vD3IjKg.jpeg" /><figcaption>Accelerate Kit</figcaption></figure><p>So that Developers can effectively use <strong>multi-core CPU</strong> threads and computing capabilities to improve application performance.</p><h4>Logical Architecture</h4><p>In the below table , it tell us logical architecture of accelerate kit for HMS Core.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/972/1*gbMjOWJAknHr3BA_9IoqFQ.png" /><figcaption>Logical Architecture picture</figcaption></figure><p>Most of current Android devices run a multi-core system. To give full play to the system, programs that can execute multiple tasks concurrently are preferred. Generally, multi-thread programs at the native layer control task execution by managing threads. Accelerate Kit provides a new multi-thread programming method by using the <strong>multi-thread library</strong>. It frees you from the thread management details so that you can focus on developing apps that can fully utilize the multi-core hardware capability of the system, promising more efficient running.</p><h4>What is the <strong>Strengths </strong>of ?</h4><ul><li><strong>Easy to use : </strong>Provides simple and rich multi-thread programming interface that allows you to focus on the implementation.</li><li><strong>High Performance:</strong> The multi-core &amp; multi-thread capabilities are fully used to improve the multi-thread performance by %10 to 20%.</li><li><strong>High Efficiency: </strong>Balances and schedules system resources and reduces system power consumption.</li></ul><h4><strong>Mainstream Multi-Thread Programming</strong></h4><p>Huawei uses “<strong>C/C++” </strong>as mainstream multi-Thread programming with its own <strong>“Huawei multithread lib”.</strong></p><p>We can say that ;high-performance and ease-to-use APIs as positive way.</p><p>it’s not have <strong>“Java interface”</strong> yet as negative way but, it will be coming in the coming days.</p><p><strong>Interdependencies</strong></p><p>You can see in the below table interdependencies of Accelerate Kit’s with specified function, dependency, Android Version and Hardware Compatibility.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*d4IVvokj1g-YUzeFOjjwdA.png" /><figcaption>Dependicies of Accelerate Kit</figcaption></figure><h3>Use Cases</h3><p>Most apps with high performance requirements are developed at the native layer using “<strong>C/C++”</strong>. However, the native layer lacks a mature multi-thread programming framework.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MJHt0rzNgKT7jvhnadARsw.png" /></figure><ul><li>Concurrent execution of tasks</li><li>Serial execution of tasks</li><li>Synchronization of tasks</li></ul><p>For example, the use of multi-threads is common in the gaming industry. You can shoot, run and perform directional movements within the character you are simultaneously in the game scene.</p><p>Moreover, it can be used in ;</p><ul><li>Photography and video (HDR,4K videos)</li><li>Entertainment(HD Decoding)</li><li>AR/VR Image beautification</li></ul><h3>Steps before Development</h3><h3>What you will need</h3><h4>Hardware Requirements</h4><ul><li>Windows, Linux, or Mac computer (desktop or laptop)</li><li>Android mobile phone (with USB connection support)</li></ul><h4>Software Requirements</h4><ul><li>Java JDK 1.7 or higher</li><li>Android Studio 3.x or higher</li><li>Android 5.0 or later</li><li>Gradle 4.6 or later</li></ul><h4>Required Knowledge</h4><ul><li>C language basics</li><li>Multithreaded programming in C</li></ul><h4>Restrictions</h4><p>Every smartphones with Android OS an its version Android 5.0 or later can be executed however HMS Core Version is maintained its uncertainty.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*HkGX-hs1Lk2xBs7Y340aCg.png" /><figcaption>Supported Devices</figcaption></figure><h3>Integration Preparations</h3><p>There are some steps we need to complete in the Huawei Accelerate Kit integration process. These are;</p><ol><li>Register as a developer.</li><li>Create an Android Studio project.</li><li>Generate a signing certificate fingerprint.</li><li>Configure the signing certificate fingerprint.</li></ol><p>you can investigate to refer this in <strong>“</strong><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/access-preparation-0000001050981313"><strong>Development Guide</strong></a><strong>”</strong> in detail.</p><h3>Integrating the HMS Core SDK</h3><p>First,you need to create an android <strong>“Native C++” </strong>project.<br>After that, you should add the following lines for <strong>“NDK build” </strong>to the <strong>/app/build.gradle</strong> file in the project directory:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1096fd84b4b19c8659e11229e1d7216b/href">https://medium.com/media/1096fd84b4b19c8659e11229e1d7216b/href</a></iframe><p><strong>arguments “-DANDROID_STL=c++_shared”:</strong> multithread-lib depends on libc++. Therefore, c++_shared must be declared in the <strong>CMake </strong>build parameters. Otherwise, some functions will not work.</p><p><strong>abiFilters “arm64-v8a”, “armeabi-v7a”:</strong> multithread-lib only supports <strong>arm64-v8a</strong> and <strong>armeabi-v7a</strong>.</p><p>In below table , you can add just like shown as necessary area.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/666/1*zkVN5I_8jnt48Y0SrR4E4A.png" /><figcaption>NDK build</figcaption></figure><h4>SDK Download and Libraries</h4><p>In the SDK file , there are some libraries that you need for the project.So you can click to download <strong>“</strong><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001051060752"><strong>SDK Download</strong></a><strong>”</strong>.</p><p>After downloading SDK, copy the header files in the SDK to the resource library. In the <strong>/app directory</strong> in the Android Studio project, create an <strong>“include”</strong> folder. Copy the files in the <strong>/include directory</strong> of the SDK to the newly created include folder.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/440/1*bp1b-l-xaf-nJVVG43zpQA.png" /><figcaption>Inside Include File</figcaption></figure><p>Copy the<strong> .so</strong> files in the SDK to the resource library.</p><p>Create a <strong>“libs”</strong> folder in the /app directory and create an <strong>“arm64-v8a”</strong> folder and an <strong>“armeabi-v7a”</strong> folder in the <strong>/app/libs</strong> directory.</p><p>Copy <strong>“libdispatch.so”</strong> , <strong>“libdispatch_stat.so”</strong> and <strong>libBlockRuntime.so</strong> from SDK’s <strong>“lib64”</strong> directory to Android Studio’s <strong>“libs/arm64-v8a8a”</strong> directory.</p><p>Copy the <strong>“libdispatch.so”</strong> <strong>“libdispatch_stat.so”</strong> and <strong>“libBlockRuntime.so”</strong> files from SDK’s /lib directory to Android Studio’s <strong>“/libs/armeabi-v7a”</strong> directory.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*sqtMC1ZE-_lVAzNyf4WBGQ.png" /><figcaption>In Libs File</figcaption></figure><p>That’s it, now your library are ready to set fire.</p><p>As of last step before development part, there are some files that you are going to modify little part on <strong>“CMakeLists.txt”</strong> file in the <strong>app/src/main/cpp </strong>directory as follows.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9a3566f2aad9117c70141a8ee365ad0d/href">https://medium.com/media/9a3566f2aad9117c70141a8ee365ad0d/href</a></iframe><p>All modifications such as adding, correction and more related parameters are described as follows:</p><ul><li><strong>target_include_directories: </strong>adds the directory of header files of the multi-thread library.</li><li><strong>add_library/set_target_properties:</strong>adds the multithread-lib related <strong>.so</strong> files. Only <strong>libdispatch.so</strong> and <strong>libBlocksRuntime.so</strong> need to be added. <strong>libdispatch_stat.so</strong> is automatically added to libdispatch.so using dlopen</li><li><strong>target_compile_option:</strong> adds the <strong>-fblocks</strong> compilation option.</li><li><strong>target_link_libraries:</strong> adds the dependency of the <strong>.so</strong> files.</li></ul><h3>Code Development Section</h3><p>In code development part , it provides us instructions for calculating <strong>“π”</strong> with the Accelerate Kit API by using <strong>“The Gregory-Leibniz infinite series”</strong> to approximate π as follows:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/283/1*5Jls_oOywdlFt-G7UC-MSw.png" /><figcaption>The Gregory-Leibniz infinite series formula</figcaption></figure><p>I seem to hear what the <strong>“The Gregory-Leibniz infinite series</strong>” is you say. You know , I said the first time I heard it.</p><p>I put here a small video which tells us about what The Gregory-Leibniz infinite series. I suggest you to watch it first before starting development to have a knowledge of it.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FlOpAVZUQGJ4%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DlOpAVZUQGJ4&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FlOpAVZUQGJ4%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e6e390079a8b6e88d0476bb58b4314c1/href">https://medium.com/media/e6e390079a8b6e88d0476bb58b4314c1/href</a></iframe><h3>Step by step code parts</h3><p><strong>1- </strong>The<strong> __block</strong> modifier is added because they assign the relevant parameters, including the number of terms <strong>(n)</strong>, the total number of threads <strong>(threads)</strong>, and the initialization of the calculation result <strong>(pi)</strong>, and the Pi needs to be updated and modified in a next block.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1efd4acdadaeff10e2ee3fa895e64140/href">https://medium.com/media/1efd4acdadaeff10e2ee3fa895e64140/href</a></iframe><p><strong>2-</strong> <strong>“dispatch_queue_create”</strong> is called to create a serial queue for Π calculation. Next, we call the task we set with the <strong>“dispatch_apply”</strong> command to execute it simultaneously multiple times in the queue. In general, it is recommended to set the specified queue to <strong>“DISPATCH_APPLY_AUTO”</strong>, which is the global concurrent queue with the priority closest to the current queue.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/5555b1c7b5fa3217edf4f0ab84093147/href">https://medium.com/media/5555b1c7b5fa3217edf4f0ab84093147/href</a></iframe><p><strong>3-</strong>Π Apply the calculation algorithm. That is, split **n** terms into thread tasks <strong>(thread = 8)</strong>. The start and end of each task is calculated based on the task ID <strong>(idx)</strong> of the current task, which in this example is 0, 1,… or 7. <strong>flag </strong>shows the plus or minus symbol of each term. <strong>Sum </strong>shows the total result of the current task.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/cfc9f3d0d94b40c05ea78886859811ca/href">https://medium.com/media/cfc9f3d0d94b40c05ea78886859811ca/href</a></iframe><p><strong>4-</strong>When the <strong>8 threads</strong> are finished, we need to call <strong>dispatch_sync</strong> and collect the results on the threads in order to calculate the sum of each task.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ee2ada9abc8f7339ec8a9959168c2e05/href">https://medium.com/media/ee2ada9abc8f7339ec8a9959168c2e05/href</a></iframe><p><strong>5-</strong>We call <strong>“dispatch_release”</strong> to release the required thread space. Each of the objects created by the APIs of the <strong>“Dispatch_xxx_create()”</strong> class corresponds to a space on the heap. Since there is no <strong>Garbage Collection</strong> developed specifically for memory management, such user-created objects must be proactively released when it determines that they are no longer needed.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e1c56e2127ae1ecde5b329bbd12b9414/href">https://medium.com/media/e1c56e2127ae1ecde5b329bbd12b9414/href</a></iframe><p><strong>6-</strong>When printing the <strong>Π</strong> number as output. The . is shown in 20 decimal places.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/bd9b33efcdebcb3cacc07ec8355f4128/href">https://medium.com/media/bd9b33efcdebcb3cacc07ec8355f4128/href</a></iframe><p><strong>Accelerated computation of π</strong> is complete. The following gives the complete code <strong>(app/src/main/cpp/native-lib.cpp).</strong></p><p><strong>7-</strong>Here is the whole code part ,You can take a look at.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0d35a89115f42271013f87c43f5d35d9/href">https://medium.com/media/0d35a89115f42271013f87c43f5d35d9/href</a></iframe><p>After applying all the steps, you will be completing multi-thread programming with Accelerate Kit.</p><p>You can see the output of application Screenshot as follows.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/370/1*aCzuoIe_p9r_gGu8tesTbw.png" /></figure><p>Here we come to the end of my Accelerate kit article, I talked about the features of this kit that can be made with multi-thread, in which areas applications can be developed to. Last but not least,and you will be learnt about this subject;</p><ul><li>Using Accelerate Kit APIs.</li><li>Integrating the Accelerate SDK.</li><li>Calling the Accelerate Kit APIs.</li></ul><p>You can examine in more detail through the reference links below.</p><p><strong>References:</strong></p><p><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/introduction-0000001050980807"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/introduction-0000001050980807</strong></a></p><p><a href="https://en.wikipedia.org/wiki/Multithreading_(computer_architecture)"><strong>https://en.wikipedia.org/wiki/Multithreading_(computer_architecture)</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a6c7ddc5507a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers/introduction-to-hms-accelerate-kit-importance-of-multithreading-and-application-on-project-a6c7ddc5507a">Introduction to HMS Accelerate Kit, Importance of Multithreading and Application on Project</a> was originally published in <a href="https://medium.com/huawei-developers">Huawei Developers</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HMS Accelerate Kit’e Giriş ,Multithreading önemi ve Proje Üzerinde Uygulanması]]></title>
            <link>https://cenkturker07.medium.com/hms-accelerate-kite-giri%C5%9F-multithreading-%C3%B6nemi-ve-proje-%C3%BCzerinde-uygulanmas%C4%B1-ae9955733dba?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/ae9955733dba</guid>
            <category><![CDATA[huawei-mobile-service]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[accelerate-kit]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[hms]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Wed, 23 Jun 2021 12:30:44 GMT</pubDate>
            <atom:updated>2021-06-23T12:30:44.912Z</atom:updated>
            <content:encoded><![CDATA[<h3>HMS Accelerate Kit’e Giriş ,Multithreading önemi ve Proje Üzerinde Uygulanması</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qLPiOorVOeW-Z1h_dBtvlw.png" /></figure><p>Herkese merhaba, Bu yazımda sizlere Accelerate Kit’in ne olduğunu, hangi amaçlarla kullanılabileceğini, avantajlarını, temel yeteneklerini, entegrasyon sürecini ve proje üzerinde nasıl uygulanacagını anlatacağım.</p><h3>Genel Bakış</h3><p>HUAWEI Accelerate Kiti, daha iyi uygulama performansını kolaylaştırmak için çok iş parçacıklı hızlandırma ve bilgi işlem hızlandırma çözümleri sunmaktadır. Günümüzde gelişen teknolojinin birçok alanında kullanılmaktadır. Ek olarak, Accelerate Kit, <strong>HMS Core 5.0 sürüm</strong>’ünde piyasaya sürülen bir yeniliktir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KJs5JmmInIx3XfZRLiBfSw.png" /><figcaption>HMS Core 5.0</figcaption></figure><h4><strong>5.0.0.300 sürümündeki Yeni Özellikler</strong></h4><p>Kolaylaştırılmış uygulama performansı için yerel katmanda çok iş parçacıklı bir programlama çerçevesi sağlamak için <strong>“multithreading-library”</strong> fonksiyonu eklenmiş olarak görüyoruz.</p><h3>Multithreading-library kavramı</h3><p>Ne yapar bu <strong>“multithread-library”</strong> diye sorarsak.. Sisteminizin size sunduğu kaynakları en verimli şekilde kullanabilmek adına çok çekirdekli donanım üzerinde yapılacak görevlerinizin sıraya alma ve yürütme işleri için gerekli API’ları sağlamaktadır.<strong>”Queue” </strong>mantığını esas alarak ,ilk giren-ilk çıkar(FIFO)yöntemi ile çalışmaktadır.</p><h3>Multithreading nedir?</h3><p>Çoklu okuma, birden çok yazılım dili için temel programlama ilkesidir ve bir programda aynı anda birden çok işin yapılmasını sağlar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*ckEihMg7ZxrzQsL89JGGLA.jpeg" /><figcaption>Multi-Threading</figcaption></figure><p>Başka bir deyişle, bir kod parçası bir işlemi gerçekleştirirken, başka bir kod parçasının da onunla paralel olarak çalıştığı anlamına gelir. Çok iş parçacıklı bir yapıya sahip olmayan programlar, ana iş parçacığı adlı bir iş parçacığı tanımlar.</p><h3>Accelerate Kit’e Giriş</h3><p>HUAWEI Accelerate Kit, birden çok iş parçacığının eşzamanlı yürütülmesini verimli bir şekilde iyileştiren çok iş parçacıklı hızlandırma yeteneği sağlar. İşletim sisteminde çekirdeğin üzerinde bulunur ve bir dizi C dili API’si olarak geliştiricilere sunulmaktadır.</p><h4>Accelerate Kit’in Temel Yetenekleri</h4><p>Hızlandırma Kiti, birçok geliştiricinin iş parçacığı aşırı yüklemesini ve uygulama performansı sorunlarını kolayca analiz etmesine yardımcı olmak için gelişmiş çok iş parçacıklı programlama ve bilgi işlem hızlandırma çözümlerini sağlar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/450/1*LlwyGNv6DVqI4u7vD3IjKg.jpeg" /><figcaption>Accelerate Kit</figcaption></figure><p>Böylece Geliştiriciler, uygulama performansını iyileştirmek için çok çekirdekli CPU iş parçacığını ve bilgi işlem yeteneklerini etkili bir şekilde kullanabilir.</p><h4>Mantıksal Mimarisi</h4><p>Aşağıdaki tablo, bize HMS Core için Accelerate kit’inin mantıksal mimarisini anlatıyor.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/972/1*gbMjOWJAknHr3BA_9IoqFQ.png" /><figcaption>Accelerate Kit Mantıksal Mimarisi</figcaption></figure><p>Mevcut Android cihazların çoğu çok çekirdekli bir sistem kullanıyor. Sisteme tam donanımlı bir oyun vermek için birden fazla görevi aynı anda yürütebilen programlar tercih edilir. Genel olarak, iş parçacıklarını yöneterek yerel katman kontrol görevinin yürütülmesinde çok iş parçacıklı programlar. Accelerate Kit, <strong>multi-thread library</strong> kullanarak yeni bir çok iş parçacıklı programlama yöntemi sağlar. Sizi iş parçacığı yönetimi ayrıntılarından kurtarır, böylece sistemin çok çekirdekli donanım kapasitesini tam olarak kullanabilen uygulamalar geliştirmeye odaklanabilirsiniz ve daha verimli çalışma vaat eder.</p><h4>Güçlü Yönleri Nelerdir?</h4><p><strong>Kolay Kullanım:</strong> Uygulamaya odaklanmanıza olanak tanıyan basit ve zengin çok iş parçacıklı programlama arabirimi sağlar.<br><strong>Yüksek Performans:</strong> Çok çekirdekli ve çoklu iş parçacığı yetenekleri, çoklu iş parçacığı performansını% 10 ile % 20 oranında geliştirmek için tamamen kullanılır.<br><strong>Yüksek Verimlilik: </strong>Sistem kaynaklarını dengeler ve planlar ve sistem güç tüketimini azaltır.</p><h4>Mainstream Multi-Thread Programlama</h4><p>Huawei, kendi <strong>“Huawei multi-thread kütüphanesi” </strong>ile ana çok iş parçacıklı programlama olarak <strong>“C / C ++” </strong>kullanır.<br>Olumlu yön olarak yüksek performanslı ve kullanımı kolay API’ler diyebiliriz.<br>ancak olumsuz yön olarak şimdilik <strong>“Java arayüzü”</strong> yok ama önümüzdeki dönemler içerisinde geleceği öngörülmektedir.</p><p><strong>Bağımlılıklar(Interdependencies)</strong></p><p>Aşağıdaki tabloda, Accelerate Kit’in belirtilen işlev, bağımlılık, Android Sürümü ve Donanım Uyumluluğu ile karşılıklı bağımlılıklarını görebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MDKWqcmdstYiD0CaD2tHbA.png" /><figcaption>Accelerate Kit Bağlılıkları</figcaption></figure><h3>Kullanım Durumları</h3><p>Yüksek performans gereksinimleri olan çoğu uygulama <strong>“C / C ++” </strong>kullanılarak yerel katmanda geliştirilir. Ancak yerel katman, olgun bir çok iş parçacıklı programlama çerçevesinden yoksundur.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MJHt0rzNgKT7jvhnadARsw.png" /><figcaption>Multithread çalıştırılan bir oyun</figcaption></figure><ul><li>Eşzamanlı görev yürütme</li><li>Görevlerin seri olarak yürütülmesi</li><li>Görevlerin senkronizasyonu</li></ul><p>Örneğin, oyun endüstrisinde çoklu iş parçacığı kullanımı yaygındır. Oyun sahnesinde eş zamanlı olarak bulunduğunuz karakter içerisinde ateş edebilir, koşabilir ve yön hareketlerini gerçekleştirebilirsiniz.</p><p>Ayrıca şu alanlarda kullanılabilir;</p><ul><li>Fotoğraf ve video (HDR, 4K videolar)</li><li>Eğlence (HD Kod Çözme)</li><li>AR / VR Görüntü güzelleştirme, iyileştirme</li></ul><h3>Geliştirme Öncesi Adımlar</h3><h4>Nelere İhtiyacınız Olacak</h4><p><strong>Donanım Gereksinimleri</strong></p><ul><li>Windows, Linux veya Mac bilgisayar (masaüstü veya dizüstü bilgisayar)</li><li>Android cep telefonu (USB bağlantı destekli)</li></ul><p><strong>Yazılım Gereksinimleri</strong></p><ul><li>Java JDK 1.7 veya üstü</li><li>Android Studio 3.x yada üstü</li><li>Android 5.0 yada sonrası</li><li>Gradle 4.6 veya üstü</li></ul><p><strong>Gerekli Bilgiler</strong></p><ul><li>C dili temelleri</li><li>C’de çok iş parçacıklı programlama</li></ul><h4>Desteklenen Cihazlar</h4><p>Android işletim sistemine sahip her akıllı telefon ve tablet ,Android 5.0 veya sonraki bir sürümü çalıştırılabilir ancak HMS Core Sürümü belirsizliğini korumaya devam ediyor.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/907/1*q2vPz3Oyiiv-xYBr_1aT8Q.png" /></figure><h3>Entegrasyon Hazırlıkları</h3><p>Huawei Accelerate Kit entegrasyon sürecinde tamamlamamız gereken bazı adımlar var. Bunlar;</p><ol><li>Geliştirici olarak kaydolun.</li><li>Bir Android Studio projesi oluşturun.</li><li>Bir imzalama sertifikası parmak izi oluşturun.</li><li>İmza sertifikası parmak izini yapılandırın.</li></ol><p>“<a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/access-preparation-0000001050981313"><strong>Geliştirme Kılavuzu</strong></a>” nda daha ayrıntılı olarak inceleyebilirsiniz.</p><h3>HMS Core SDK’nın Entegrasyonu</h3><p>Öncelikle bir android <strong>“Native C ++”</strong> projesi oluşturmanız gerekir.<br>Bundan sonra, proje dizinindeki <strong>/app/build.gradle</strong> dosyasına <strong>“NDK build” </strong>için aşağıdaki satırları eklemelisiniz:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1096fd84b4b19c8659e11229e1d7216b/href">https://medium.com/media/1096fd84b4b19c8659e11229e1d7216b/href</a></iframe><p><strong>arguments “-DANDROID_STL=c++_shared”:</strong> multithread-lib, libc++’a bağlıdır. Bu nedenle, c++_shared’in <strong>CMake </strong>derleme parametrelerinde bildirilmesi gerekir. Aksi takdirde, bazı işlevler çalışmayacaktır.</p><p><strong>abiFilters “arm64-v8a”, “armeabi-v7a”:</strong> multithread-lib yalnızca <strong>arm64-v8a</strong> ve <strong>armeabi-v7a</strong>’yı destekler.</p><p><strong>jniLibs.srcDirs = [‘libs’]:</strong> <strong>.so</strong> dosyalarının dizinini belirtir.</p><p>Aşağıdaki tabloda, gerekli alanı gösterildiği gibi ekleyebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/666/1*Qzl2RmYrqo6qXtr8nup67A.png" /><figcaption>NDK build</figcaption></figure><h4>SDK İndirme ve Kitaplıklar</h4><p>SDK dosyasında proje için ihtiyaç duyduğunuz bazı kütüphaneler bulunmaktadır. <strong>“</strong><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001051060752"><strong>SDK İndir</strong></a><strong>”</strong> i indirmek için tıklayabilirsiniz.</p><p>SDK’yı indirdikten sonra, SDK’daki başlık dosyalarını kaynak kitaplığına kopyalayın. Android Studio projesindeki <strong>/ app dizininde</strong> bir <strong>“include” </strong>klasörü oluşturun. SDK’nın <strong>/ include dizinindeki </strong>dosyaları yeni oluşturulan klasörün içerisine kopyalayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/440/1*bp1b-l-xaf-nJVVG43zpQA.png" /><figcaption>Include File</figcaption></figure><p>SDK’daki <strong>.so</strong> dosyalarını kaynak kitaplığına kopyalayın.</p><p>/ App dizininde bir <strong>“libs”</strong> klasörü oluşturun ve <strong>/ app / libs</strong> dizininde bir <strong>“arm64-v8a”</strong> klasörü ve bir <strong>“armeabi-v7a”</strong> klasörü oluşturun.</p><p>SDK’nın <strong>“lib64 ” </strong>dizinindeki <strong>“libdispatch.so”</strong> , <strong>“libdispatch_stat.so” </strong>ve<strong> libBlockRuntime.so</strong>’yu Android Studio’nun <strong>“ libs / arm64-v8a8a”</strong> dizinine kopyalayın.</p><p>SDK’nın / lib dizinindeki <strong>“libdispatch.so”</strong> <strong>“libdispatch_stat.so” </strong>ve<strong> “libBlockRuntime.so”</strong> dosyalarını Android Studio’nun <strong>“/ libs / armeabi-v7a”</strong> dizinine kopyalayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*ZoiDs1bFUeq5mnqsrOXT4Q.png" /><figcaption>In libs file</figcaption></figure><p>İşte bu, artık hazırsınız kütüphaneniz ateşlemeye hazır.</p><p>Geliştirme kısmından önceki son adımda ise <strong>app / src / main / cpp </strong>dizininde <strong>“CMakeLists.txt”</strong> dosyasında küçük bir kısmını değiştireceğiniz bazı dosyalar aşağıdaki gibidir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9a3566f2aad9117c70141a8ee365ad0d/href">https://medium.com/media/9a3566f2aad9117c70141a8ee365ad0d/href</a></iframe><p>Ekleme, düzeltme ve diğer ilgili parametreler gibi tüm değişiklikler aşağıda açıklanmıştır:</p><ul><li><strong>target_include_directories:</strong> multi-thread library başlık dosyalarının dizinini ekler.</li><li><strong>add_library/set_target_properties:</strong>multithread-lib ile ilgili <strong>.so</strong> dosyalarını ekler. Yalnızca <strong>libdispatch.so</strong> ve <strong>libBlocksRuntime.so</strong>’nun eklenmesi gerekir. <strong>libdispatch_stat.so</strong>, dlopen kullanılarak <strong>libdispatch.so</strong>’ya otomatik olarak eklenir.</li><li><strong>target_compile_option:</strong> <strong>-fblocks</strong> derleme seçeneğini ekler.</li><li><strong>target_link_libraries:</strong> <strong>.so</strong> dosyalarının bağımlılığını ekler.</li></ul><h3>Kod Geliştirme Bölümü</h3><p>Kod geliştirme bölümünde, Accelerate Kit API ile <strong>“The Gregory-Leibniz sonsuz serisini”</strong> kullanarak aşağıdaki gibi<strong> “π”</strong> hesaplamasına yönelik talimatlar sağlamaktadır:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/283/1*5Jls_oOywdlFt-G7UC-MSw.png" /><figcaption>The Gregory-Leibniz infinite series formülü</figcaption></figure><p><strong>“Gregory-Leibniz sonsuz dizisi”</strong> de neymiş dediğinizi duyar gibiyim. Biliyor musunuz bende sizin gibi aynı tepki vermiştim ilk duyduğumda.</p><p>Buraya Gregory-Leibniz sonsuz serisinin ne olduğunu anlatan küçük bir video koydum. Hakkında bilgi sahibi olmak için geliştirmeye başlamadan önce izlemenizi öneririm.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FlOpAVZUQGJ4%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DlOpAVZUQGJ4&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FlOpAVZUQGJ4%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e6e390079a8b6e88d0476bb58b4314c1/href">https://medium.com/media/e6e390079a8b6e88d0476bb58b4314c1/href</a></iframe><h3>Adım adım kod blokları</h3><p><strong>1-</strong>Terim sayısı <strong>(n)</strong>, toplam görev sayısı <strong>(threads)</strong> ve hesaplama sonucunun başlatılması <strong>(pi)</strong> dahil olmak üzere ilgili parametreleri atamaları ve Pi’nin sonraki bir blokta güncellenmesi ve değiştirilmesi gerektiğinden, <strong>__block</strong> değiştiricisi eklenir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/1efd4acdadaeff10e2ee3fa895e64140/href">https://medium.com/media/1efd4acdadaeff10e2ee3fa895e64140/href</a></iframe><p><strong>2-</strong> <strong>“dispatch_queue_create” </strong>Π hesaplaması için bir seri kuyruk oluşturmak adına çağırılmaktadır. Ardından, <strong>“dispatch_apply” </strong>komutu ile belirlediğimiz görevi, kuyrukta birden çok kez eşzamanlı olarak yürütmek için çağırırız. Genel olarak, belirtilen kuyruğu, önceliği mevcut kuyruğa en yakın olan global eşzamanlı kuyruk olan <strong>“DISPATCH_APPLY_AUTO”</strong> olarak ayarlamanız önerilir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/5555b1c7b5fa3217edf4f0ab84093147/href">https://medium.com/media/5555b1c7b5fa3217edf4f0ab84093147/href</a></iframe><p><strong>3-</strong>Π hesaplama algoritmasını uygulayın. Yani, ** n ** terimlerini iş parçacığı görevlerine ayırın <strong>(thread = 8)</strong>. Her görevin başlangıcı ve bitişi, geçerli görevin bu örnekte 0, 1,… veya 7 olan görev kimliğine <strong>(idx) </strong>göre hesaplanır. <strong>flag</strong>, her terimin artı veya eksi sembolünü gösterir. <strong>Sum</strong>, geçerli görevin toplam sonucunu gösterir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/cfc9f3d0d94b40c05ea78886859811ca/href">https://medium.com/media/cfc9f3d0d94b40c05ea78886859811ca/href</a></iframe><p><strong>4-</strong> <strong>8 thread</strong>’in işlemi tamamlandığında her görevin toplamını hesaplamak adına <strong>dispatch_sync</strong>’i çağırırark threadler üzerindeki sonucları toplamamız gerekmektedir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ee2ada9abc8f7339ec8a9959168c2e05/href">https://medium.com/media/ee2ada9abc8f7339ec8a9959168c2e05/href</a></iframe><p><strong>5-</strong>Gerekli thread alanını serbest bırakmak için <strong>“dispatch_release”</strong> çağırıyoruz. <strong>“Dispatch_xxx_create ()”</strong> sınıfının API’leri tarafından oluşturulan nesnelerin her biri, öbek üzerindeki bir boşluğa karşılık gelir. Özellikle bellek yönetimi için geliştirilen <strong>Garbage Collection</strong> olmadığından, kullanıcı tarafından oluşturulan bu tür nesnelerin artık gerekli olmadığını belirlediğinde proaktif olarak serbest bırakılması gerekir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e1c56e2127ae1ecde5b329bbd12b9414/href">https://medium.com/media/e1c56e2127ae1ecde5b329bbd12b9414/href</a></iframe><p><strong>6-Π </strong>sayısını output olarak ekrana bastırırken . ,20 ondalık basamak içinde gösterilmektedir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/bd9b33efcdebcb3cacc07ec8355f4128/href">https://medium.com/media/bd9b33efcdebcb3cacc07ec8355f4128/href</a></iframe><p><strong>Accelerate π hesaplaması</strong> tamamlandı. Aşağıda tam kod <strong>(app / src / main / cpp / native-lib.cpp)</strong> verilmektedir.</p><p><strong>7-</strong>İşte kod kısmının tamamı,buradan tekrar inceleyebilirsiniz.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0d35a89115f42271013f87c43f5d35d9/href">https://medium.com/media/0d35a89115f42271013f87c43f5d35d9/href</a></iframe><p>Tüm adımları uyguladıktan sonra, Accelerate Kit ile çok iş parçacıklı programlamayı tamamlamış olacaksınız..<br>Uygulamanın ekran görüntüsü çıktısını aşağıdaki gibi görebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/370/1*aCzuoIe_p9r_gGu8tesTbw.png" /><figcaption>Uygulama çıktısı</figcaption></figure><p>Accelerate kit yazımın sonuna geldik, bu kitin multi-thread ile kullanımı, hangi alanlarda uygulama geliştirilebileceğini anlattım. Son olarak, Accelerate Kit hakkında,aşağıdaki konular hakkında bilgi sahibi olacaksınız;</p><ul><li>Accelerate Kit API’lerini Kullanma,</li><li>Accelerate SDK’yı entegre etme,</li><li>Accelerate Kit API’lerini çağırma</li></ul><p>Aşağıdaki referans linkler’i üzerinden daha ayrıntılı inceleme yapabilirsiniz.</p><p><strong>Referanslar:</strong></p><p><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/introduction-0000001050980807"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/introduction-0000001050980807</strong></a></p><p><a href="https://en.wikipedia.org/wiki/Multithreading_(computer_architecture)"><strong>https://en.wikipedia.org/wiki/Multithreading_(computer_architecture)</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ae9955733dba" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AGC -Crash Servisi (Android)]]></title>
            <link>https://medium.com/huawei-developers-tr/agc-crash-servisi-android-b2575487e33d?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/b2575487e33d</guid>
            <category><![CDATA[crash]]></category>
            <category><![CDATA[appgallery-connect]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[agc]]></category>
            <category><![CDATA[hms]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Fri, 04 Dec 2020 10:14:47 GMT</pubDate>
            <atom:updated>2020-12-04T10:14:47.274Z</atom:updated>
            <content:encoded><![CDATA[<p>Herkese merhaba, bu yazımda <strong>AppGallery Connect</strong> hizmetlerinden biri olan Crash hizmetlerinden bahsedeceğim.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/988/1*AelzlCnBLbXdUOFAWJ11Ag.jpeg" /><figcaption>Crash Service</figcaption></figure><h3>Crash hizmeti nedir?</h3><p><strong>AppGallery Connect</strong>’in çökme hizmeti otomatik olarak çöktüğünü bildirmekte ve çökme hizmetini entegre ettikten sonra çökme analizine izin vermektedir, uygulamanız çökmeleri otomatik olarak <strong>AppGallery Connect</strong>’e raporlayarak gerçek zamanlı olarak çökme raporları oluşturacaktır. Raporlarda sağlanan bol miktarda bilgi, çökmeleri bulmanıza ve çözmenize yardımcı olacaktır.</p><h3>Neden Crash servisine ihtiyaç duyarız ?</h3><p>Uygulamalar, geniş kullanıcı tabanı, farklı cihaz modellerini ve karmaşık ağ ortamını göz önünde bulundurarak piyasaya sürülmeden önce testleri tamamlamış olsa da uygulamaların ara sıra çökmesi kaçınılmazdır. Crash’lar kullanıcı deneyimini tehlikeye atar, Kullanıcılar çökmeler nedeniyle uygulamanızı kaldırabilir ve uygulamanız iyi feedback almama ihtimli artacaktır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*PWVVcJQOobSZ33w1zgkARw.jpeg" /></figure><p>Crash’ları bulmak için incelemelerden yeterli crash bilgisi alamazsınız, bu nedenle bunları kısa sürede çözemezsiniz. Bu, işinize ciddi şekilde zarar verecektir. Bu nedenle, daha verimli olmak için uygulamalarımızdaki crash hizmetlerini kullanmamız gerekiyor.</p><h3>Crash hizmetini nasıl entegre edebiliriz?</h3><p>Çok basit ! , yalnızca Crash SDK’yı uygulamanıza entegre etmeniz gerekir. Daha sonra SDK, herhangi bir kodlama yapmadan ilgili işlevleri uygulayabilir. Size ilerleyen bölümde SDK’nın nasıl uygulanacağını anlatacağım.</p><h3>Crash Hizmetine Başlarken</h3><p>Kendi uygulamanıza entegre etmek için ihtiyaç duyduğunuz bazı prosedürler vardır. İşte aşağıdaki adımlar, bunun içindir;</p><h4>1-AppGallery Connect SDK’sını entegre etme</h4><p>SDK’yı <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-get-started"><strong>AppGallery Connect</strong></a>’e nasıl entegre edeceğinizle ilgili gerekli tüm bilgileri bulacaksınız.</p><h4>2-HUAWEI Analiz Kit’ini Etkinleştirme</h4><p>Crash hizmeti, kilitlenme olaylarını bildirirken HUAWEI Analytics Kit’in özelliklerini kullanır. Bu nedenle, Crash SDK’yı entegre etmeden önce HUAWEI Analytics Kit’i etkinleştirmeniz gerekir. Ayrıntılar için lütfen<a href="https://developer.huawei.com/consumer/en/doc/development/HMS-Guides/79044452"> <strong>Servis Etkinleştirme</strong></a> bölümüne bakın.</p><h4>3-HUAWEI Analiz Kit’ini Entegre etme</h4><p>HUAWEI Analytics Kit’i kullanmadan önce, aşağıdaki kodu uygulama düzeyindeki <strong>build.gradle</strong> dosyasına (genellikle <strong>app </strong>dizininde) ekleyerek entegre etmeniz gerekir:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/5cdb82be56bdad3ec9edc12afccff06b/href">https://medium.com/media/5cdb82be56bdad3ec9edc12afccff06b/href</a></iframe><h4>4-Crash SDK’yı Entegre Etme</h4><p>Crash SDK’yı entegre etmek için aşağıdaki kodu uygulama düzeyinde <strong>build.gradle</strong> dosyasına (genellikle <strong>app</strong> dizininde) ekleyin:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c11206672ba126b0777cdaef53fa9c56/href">https://medium.com/media/c11206672ba126b0777cdaef53fa9c56/href</a></iframe><p>Bu adımları uyguladıktan sonra, projenizin güncellenmiş sürümüyle yeniden oluşturmak için sağ üstteki <strong>“Sync Now”</strong> düğmesine tıklamayı unutmayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/237/1*__M2omVCcpqDerhaluKmSw.png" /></figure><h4>AndroidManifest İzni</h4><p>Ayrıca, aşağıdaki izin komutlarını <strong>Androidmanifest.xml</strong> dosyanıza eklemeniz gerekir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/80125bab24f2d9e45c7d96677b4fb958/href">https://medium.com/media/80125bab24f2d9e45c7d96677b4fb958/href</a></iframe><h3>Kod Geliştirme Bölümü</h3><p><strong>MainActivity.java</strong>’da parça parça kod bloklarını görebilirsiniz.</p><p><strong>MakeCrash </strong>düğmesine dokunulduğunda bir kilitlenmeyi tetiklemek için <strong>AGConnectCrash.testIt</strong> yöntemini çağırmak için aşağıdaki kodu ekleyin.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/471d6feb67f732dce14888110a2df269/href">https://medium.com/media/471d6feb67f732dce14888110a2df269/href</a></iframe><p><strong>CrashCollectionON</strong> düğmesine dokunulduğunda kilitlenme verisi raporlamasını etkinleştirmek için <strong>AGConnectCrash.enableCrashCollection </strong>yöntemini çağırmak için aşağıdaki kodu ekleyin.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/34494f04e372e8890b0d08611f2da532/href">https://medium.com/media/34494f04e372e8890b0d08611f2da532/href</a></iframe><p><strong>CrashCollectionOFF </strong>düğmesine dokunulduğunda kilitlenme verisi raporlamasını devre dışı bırakma kodunu ekleyin.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ccc910d7bf32a3d3fd28c5f71a9db113/href">https://medium.com/media/ccc910d7bf32a3d3fd28c5f71a9db113/href</a></iframe><p>Özel bir kullanıcı kimliği tanımlamak için <strong>AGConnectCrash.setUserId</strong>, özel günlükleri kaydetmek için <strong>AGConnectCrash.log</strong> çağırma ve <strong>CustomReport </strong>düğmesine dokunulduğunda özel bir <strong>key-value </strong>çifti tanımlamak için <strong>AGConnectCrash.setCustomKey</strong>’i çağırma kodunu ekleyin.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/252942ca0bb0c5efdd4b62708fedb8e2/href">https://medium.com/media/252942ca0bb0c5efdd4b62708fedb8e2/href</a></iframe><p><strong>MainActivity.xml </strong>içinde yer alan aşağıdaki tüm kod parçacıgı , uygulama arayüzünü oluşturur.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/477a67bf75c108c420bcb9ec20538b84/href">https://medium.com/media/477a67bf75c108c420bcb9ec20538b84/href</a></iframe><p>Kendi projeniz üzerinde <strong>xml</strong> kodlarını ekledikten sonra göreceğiniz uygulama arayüzü aşağıdaki gibidir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/363/1*x14Amq6g_TCz-OffwCjCmA.png" /></figure><p>Artık, kod geliştirme bölümünü tamamlamş bulunmaktayız. Sonraki adım, projenizi gerçekleştirdikten sonra AppGallery Connect’te sonuçları izlemek ve analiz etmek olacak.</p><h3>AppGallery Connect üzerinde Crash Hizmetini Etkinleştirme</h3><p><strong>AppGallery Connect</strong>’i imzaladıktan sonra, ilk kez kullanacaksanız, çökme hizmetini etkinleştirmek için bu adımları izlemeniz gerekir.</p><p><strong>My project →Project Settings → Quality → Enable Now</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lW7_rE7I6v8qHP83kSoLXw.png" /></figure><h3>Varolan Crash’ları nasıl çözümleyebiliriz?</h3><p><strong>AppGallery Connect</strong>’te oturum açarak, kilitlenme sayısı, etkilenen kullanıcı sayısı ve kilitlenme oranı gibi kilitlenme göstergelerini kontrol edebilirsiniz. Çözmek istediğiniz kilitlenmeyi bulmak için tarihi saate, işletim sistemine, uygulama sürümüne, cihaz türüne ve diğer kriterlere göre filtreleyebilirsiniz. Ek olarak, çökmenin ayrıntılarını kontrol edebilir, buna göre çökmeyi bulabilir veya doğrudan çökme yığınına göre çökmenin meydana geldiği koda gidebilir ve çökmeyi çözebilirsiniz.</p><h3>Crash Notification nedir?</h3><p>Crash notification hizmeti, uygulamanızı çökmelere karşı gerçek zamanlı olarak izleyecektir. Kritik bir kilitlenme meydana geldiğinde, bildirim işlevini etkinleştirdiyseniz, e-posta bildirimleri alırsınız, böylece bunları hemen çözebilirsiniz.</p><h4>Crash Notification Nasıl Etkinleştirilir ?</h4><p>Crash bildirimlerini etkinleştirmek için lütfen aşağıdaki adımları izleyin.</p><p>1. <strong>AppGallery Connect</strong>’te oturum açın ve <strong>Users and permissions</strong>’i seçin.</p><p>2. Go to<strong> User →Personal information</strong>.</p><p>3. <strong>Bildirim</strong> alanında, <strong>Crash </strong>bildirimi için <strong>E-posta</strong> ve <strong>SMS </strong>mesajı altındaki onay kutularını seçin (<strong>Büyük bir çökme durumunda beni bilgilendir</strong>) ve Kaydet’i tıklayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2DaK1Xo1wVN7SQoN4Pw-sg.png" /></figure><h3>Crash Hizmeti Test Sonucunu İzleme ve Analiz Etme</h3><p>Yapılandırma sürecini tamamladıktan sonra, crash hizmetlerinizin sonuçlarını görebilirsiniz.</p><p><strong>“Statistics”</strong> sekmesinde, çökme hakkında bazı çıktılar bulacaksınız aşağıdaki gibi;</p><ul><li>App crashed times,</li><li>Crash Rate,</li><li>Affected Users,</li><li>In time type</li></ul><p>Ek olarak, sol üstte <strong>“Add Filter” </strong>i seçebilir ve sonucu şu filtrelemelere göre kontrol edebilirsiniz;</p><ul><li>Operating System</li><li>App version,</li><li>Device</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*B8eOzYhl0_jdkxAV_PXe7Q.png" /><figcaption>Crash</figcaption></figure><p>Ancak<strong> “Set crash notification”</strong> seçeneğine tıklayarak <strong>threshold </strong>özelleştirebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DNMnp1GWi24r1Yr-ZpKCnQ.png" /><figcaption>Set Crash Notification</figcaption></figure><p>Ayrıca, tüm kilitlenme sonuçlarını <strong>.csv</strong> formatında doğrulamak için <strong>“Download Report”</strong> a tıklayarak raporu indirebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/633/1*8nuj-phr1rRC4n7K8fnPqA.png" /></figure><p><strong>”Problems ”</strong> sekmesinde, kilitlenmenin ana sorununun nedenini görüntüleyebilirsiniz.</p><p>katkı olarak, kontrol edebilir;</p><ul><li>Event Type,</li><li>Event,</li><li>Affected User,</li><li>Last occurence time.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CMBAD313SxlD9S9aARDlPQ.png" /><figcaption>Problems tab</figcaption></figure><p>Burada problemin adı olan <strong>“java.lang.NullPointerException”</strong> üzerine tıkladıktan sonra detaylı olarak inceleme şansı elde edeceksiniz.</p><p>Aşağıdaki tabloda kontrol etmeniz gereken bilgiler olacak;</p><ul><li>Stack,</li><li>Logs,</li><li>Status,</li><li>Information.</li></ul><p>Şimdi yukarıdaki konuları açıklayacağız, bundan sonra <strong>“Search by User”</strong> sekmesine geçeceğiz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t1xKbixg-FGZdfNB6cf8vQ.png" /><figcaption>Stack tab</figcaption></figure><p><strong>“Logs” </strong>sekmesinde,günlüklere göre filtreleyerek şu kriterlere göre göz atabilirsiniz.</p><ul><li>All</li><li>Debug,</li><li>Info,</li><li>Warning</li><li>Error</li></ul><p>Ayrıca<strong>“Enter a keyword” </strong>kutucuğu ile arama yapabilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*t4YIrwTkhMOkmaV5Ox8AlA.png" /><figcaption>Log tab</figcaption></figure><p><strong>“Status”</strong> sekmesinde, bir çökmenin meydana geldiği uygulama durumunu almak için durumu kaydetmek üzere özel bir <strong>key/value</strong> çifti ekleyebilirsiniz. Aslında burada, çökme meydana gelmesi için yarattığınız kendi özel değerlerinizi inceleyeceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3qkHVra-YGFsoN1rXKfKEw.png" /><figcaption>Status tab</figcaption></figure><p><strong>“Information”</strong> sekmesinde, aşağıdakilerle ilgili bilgilere göz atmış olacaksınız;</p><ul><li>App</li><li>Operating System</li><li>Device</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eZJyJrijyy-kE5dTXYnUDg.png" /><figcaption>Information tab</figcaption></figure><p><strong>“Search by user”</strong> sekmesinde, çökmelerle ilgili bazı çıktılar bulacaksınız;</p><ul><li>Occuring time,</li><li>User ID,</li><li>Event type,</li><li>Problems</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2UQrV1ZFEj7WEIj27oLv2Q.png" /></figure><h3>Bir Crash Raporunu Özelleştirme</h3><p>İsterseniz bu kırmızı işaretli alan parametrelerini özelleştirerek kendi çarpışma raporunuzu oluşturabilirsiniz, böylelikle analiziniz daha verimli ve anlaşılır olacaktır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/837/1*IKONU8gFgSTlfdQNfbg2GA.png" /><figcaption>customizing own crash report</figcaption></figure><h3>SSS</h3><p><strong>S:</strong> Tüm kilitlenme raporlarını AppGallery Connect’ten dışa aktarabilir miyim?<br><strong>C:</strong> Elbette, kendi AGC kilitlenme sayfanıza rapor <strong>.csv</strong> formatında indirebilirsiniz.</p><p><strong>S:</strong> AGC aracılığıyla uygulamamın herhangi bir nedenle çöktüğünü görebilir miyim?<br><strong>C: </strong>Evet, Sorunlar sekmesine tıklayarak, Yığın, Günlük, Durum ve Bilgi olarak adlandırılan 4 farklı sekme göreceksiniz, her sekme aradığınız şey hakkında size farklı bir çözüm verecektir.</p><p><strong>S:</strong> Uygulamamda testi çalıştırdığımda kilitlenme raporunu neden hemen AGC’de göremiyorum? Görmek için herhangi bir süre var mı ve verilerin ne kadar süreyle saklanıyor?<br><strong>C:</strong> Test raporunun size yansıması ortalama olarak en az 1 dakikadır ve bu veriler size <strong>saatlik</strong>, <strong>24 saatlik</strong> ve <strong>7 günlük</strong>,<strong> 30 günlük </strong>ve <strong>90 günlük</strong> verilerin sonuçlarını sunar.</p><p>Crash Servis yazımın sonuna geldik, umarım bahsettiklerim size faydalı olur, bir sonraki yazımda görüşmek üzere, hepinize iyi günler dilerim …</p><h4>Referanslar</h4><p><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-crash-introduction">https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-crash-introduction</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b2575487e33d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers-tr/agc-crash-servisi-android-b2575487e33d">AGC -Crash Servisi (Android)</a> was originally published in <a href="https://medium.com/huawei-developers-tr">Huawei Developers - Türkiye</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AGC- Crash Service (Android)]]></title>
            <link>https://medium.com/huawei-developers/agc-crash-service-android-854d26a69894?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/854d26a69894</guid>
            <category><![CDATA[appgallery-connect]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[hms]]></category>
            <category><![CDATA[agc]]></category>
            <category><![CDATA[crash]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Fri, 04 Dec 2020 10:11:56 GMT</pubDate>
            <atom:updated>2020-12-04T10:51:52.044Z</atom:updated>
            <content:encoded><![CDATA[<p>Hello everyone, in this article I am going to talk about Crash services which one of the <strong>AppGallery Connect</strong> services.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/988/1*AelzlCnBLbXdUOFAWJ11Ag.jpeg" /><figcaption>Crash Service</figcaption></figure><h3>What is the crash service ?</h3><p>The crash service of <strong>AppGallery Connect</strong> reports crashes automatically and allows crash analysis after integrating the crash service, your app will automatically report crashes to <strong>AppGallery Connect </strong>for it to generate crash reports in real time. The abundant information provided in reports will help you locate and resolve crashes.</p><h3>Why do we need the crash service ?</h3><p>Although apps have gone through rounds the tests before release considering the large user base diverse device models and complex network environment. it’s inevitable for apps to crash occasionally. Crashes compromise user experience, Users may even uninstall you app due to crashes and your app is not going to get good reviews.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*PWVVcJQOobSZ33w1zgkARw.jpeg" /></figure><p>You can’t get sufficient crash information from reviews to locate crashes, Therefore you can’t resolve them shortly. This will severely harm your business. That’s why we need to use the crash services in our apps to be more efficient.</p><h3>How can we integrate Crash service ?</h3><p>It’s piece of cake ! , you only need to integrate the Crash SDK to your app. Then the SDK can implement related functions without any coding. I’m going to tell you how to implement the SDK in progressive section.</p><h3>Getting Started on Crash Service</h3><p>There are some procedures that you need to apply it into your own app.Here is the following steps ,go for it;</p><h4>1-Integrating the AppGallery Connect SDK</h4><p>You will find out whole necessary information about how to integrate the SDK on <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-get-started"><strong>AppGallery Connect</strong></a><strong>.</strong></p><h4>2-Enabling HUAWEI Analytics Kit</h4><p>The Crash service uses capabilities of HUAWEI Analytics Kit when reporting crash events. Therefore, you must enable HUAWEI Analytics Kit before integrating the Crash SDK. For details, please refer to <a href="https://developer.huawei.com/consumer/en/doc/development/HMS-Guides/79044452"><strong>Service Enabling</strong></a>.</p><h4>3-Integrating HUAWEI Analytics Kit</h4><p>Before using HUAWEI Analytics Kit, you must integrate it by adding the following code to the app-level <strong>build.gradle</strong> file (usually in the <strong>app</strong> directory):</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/5cdb82be56bdad3ec9edc12afccff06b/href">https://medium.com/media/5cdb82be56bdad3ec9edc12afccff06b/href</a></iframe><h4>4-Integrating the Crash SDK</h4><p>Add the following code to the app-level <strong>build.gradle</strong> file (usually in the <strong>app</strong> directory) to integrate the Crash SDK:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c11206672ba126b0777cdaef53fa9c56/href">https://medium.com/media/c11206672ba126b0777cdaef53fa9c56/href</a></iframe><p>After applying these steps, don’t forget to click on<strong>“Sync Now”</strong> button on the right top to rebuild with updated version of your project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/237/1*__M2omVCcpqDerhaluKmSw.png" /></figure><h4>AndroidManifest Permission</h4><p>Also,you need to add these below permission commands into your <strong>Androidmanifest.xml.</strong></p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/80125bab24f2d9e45c7d96677b4fb958/href">https://medium.com/media/80125bab24f2d9e45c7d96677b4fb958/href</a></iframe><h3>Code Development Part</h3><p>You can see piece by piece code blocks in <strong>MainActivity.java</strong></p><p>Add the code for calling the <strong>AGConnectCrash.testIt </strong>method to trigger a crash when the <strong>makeCrash </strong>button is tapped.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/471d6feb67f732dce14888110a2df269/href">https://medium.com/media/471d6feb67f732dce14888110a2df269/href</a></iframe><p>Add the code for calling the <strong>AGConnectCrash.enableCrashCollection </strong>method to enable crash data reporting when the <strong>CrashCollectionON</strong> button is tapped.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/34494f04e372e8890b0d08611f2da532/href">https://medium.com/media/34494f04e372e8890b0d08611f2da532/href</a></iframe><p>Add the code for disabling crash data reporting when the <strong>CrashCollectionOFF </strong>button is tapped.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ccc910d7bf32a3d3fd28c5f71a9db113/href">https://medium.com/media/ccc910d7bf32a3d3fd28c5f71a9db113/href</a></iframe><p>Add the code for calling <strong>AGConnectCrash.setUserId</strong> to define a custom user ID, calling <strong>AGConnectCrash.log</strong> to record custom logs, and calling <strong>AGConnectCrash.setCustomKey</strong> to define a custom key-value pair when the <strong>CustomReport</strong> button is tapped.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/252942ca0bb0c5efdd4b62708fedb8e2/href">https://medium.com/media/252942ca0bb0c5efdd4b62708fedb8e2/href</a></iframe><p>Here is the all <strong>MainActivity.xml</strong> layout, it creates application interface.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/477a67bf75c108c420bcb9ec20538b84/href">https://medium.com/media/477a67bf75c108c420bcb9ec20538b84/href</a></iframe><p>The app interface you will see after applying xml to your own project is as follows.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/363/1*x14Amq6g_TCz-OffwCjCmA.png" /></figure><p>So, we completed code development part, the next step is tracking and analysing results at AppGallery Connect ,after executing your project.</p><h3>Enabling Crash Service On AppGallery Connect</h3><p>After signing <a href="https://developer.huawei.com/consumer/en/agconnect/"><strong>AppGallery Connect</strong></a><strong> ,</strong>you need to follow these steps to enable crash service, if you are going to use it first time.</p><p><strong>My project →Project Settings → Quality → Enable Now</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lW7_rE7I6v8qHP83kSoLXw.png" /></figure><h3>How can we resolve the existing crashes ?</h3><p>With signing in to <a href="https://developer.huawei.com/consumer/en/agconnect/"><strong>AppGallery Connect</strong></a> ,you can check crash indicators including number of crashes, number of affected users and crash rate. You can filter date by time ,OS, app version, device type and other criteria to find the crash you want to resolve. In addition, you can check the details of the crash, locate the crash accordingly or directly go to the code where the crash occurs based on the crash stack and resolve the crash.</p><h3>What is crash notification ?</h3><p>The crash service will monitor your app in real time for crashes, When a critical crash occurs, if you have enabled the notification function, you will receive email notifications , so you can resolve them promptly.</p><h4>How to Enable Crash Notifications ?</h4><p>Please follow the below steps to enable crash notifications.</p><p>1. Sign in to <a href="https://developer.huawei.com/consumer/en/service/josp/agc/index.html"><strong>AppGallery Connect</strong></a> and select <strong>Users and permissions</strong>.</p><p>2. Go to <strong>User</strong> &gt; <strong>Personal information</strong>.</p><p>3. In the <strong>Notification</strong> area, select the check boxes under <strong>Email</strong> and <strong>SMS message</strong> for <strong>Crash notification (Notify me of a major crash)</strong> and click <strong>Save</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2DaK1Xo1wVN7SQoN4Pw-sg.png" /></figure><h3>Monitoring &amp; Analyzing Crash Service Test Result</h3><p>After completing configuration process, you can see the results for your crash services.</p><p>In <strong>“Statistics ” </strong>tab, you will find out some outputs about crash. Such as;</p><ul><li>How much times your app crashed,</li><li>Crash Rate,</li><li>Affected Users,</li><li>In time type</li></ul><p>Additionally, you can select <strong>“Add Filter”</strong> on left top and check out the result as;</p><ul><li>Operating System</li><li>App version,</li><li>Device</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*B8eOzYhl0_jdkxAV_PXe7Q.png" /><figcaption>Crash</figcaption></figure><p>However, you can customize the <strong>threshold </strong>with clicking on “<strong>Set crash notification</strong>”.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DNMnp1GWi24r1Yr-ZpKCnQ.png" /><figcaption>Set Crash Notification</figcaption></figure><p>You can also download report by clicking on <strong>“Download Report” </strong>to verify in <strong>.csv </strong>format the all crash results.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/633/1*8nuj-phr1rRC4n7K8fnPqA.png" /></figure><p>In <strong>”Problems ” </strong>tab, you can view main problem of crash’ occuring reaason.</p><p>additively, can check out ;</p><ul><li>Event Type,</li><li>Event,</li><li>Affected User,</li><li>Last occurence time.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CMBAD313SxlD9S9aARDlPQ.png" /><figcaption>Problems tab</figcaption></figure><p>After clicking on the name of the problem which is <strong>“java.lang.NullPointerException”</strong> here, you will get a chance to examine in detail.</p><p>In below table, you will have information to check such as;</p><ul><li>Stack,</li><li>Logs,</li><li>Status,</li><li>Information.</li></ul><p>Now we are going to explain above matters ,after that jump into <strong>“Search by User” </strong>tab.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t1xKbixg-FGZdfNB6cf8vQ.png" /><figcaption>Stack tab</figcaption></figure><p>In <strong>“Logs”</strong> tab , you can go through logs by filtering according to ;</p><ul><li>All</li><li>Debug,</li><li>Info,</li><li>Warning</li><li>Error</li></ul><p>Also you can get search with using the box named as <strong>“Enter a keyword”.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*t4YIrwTkhMOkmaV5Ox8AlA.png" /><figcaption>Log tab</figcaption></figure><p>In <strong>“Status” </strong>tab , To obtain the app status in which a crash occurs, you can add a custom <strong>“key-value” </strong>pair to record the status. Actually here, you will have examine your own custom values that you created to occur crash.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3qkHVra-YGFsoN1rXKfKEw.png" /><figcaption>Status tab</figcaption></figure><p>In<strong> “Information”</strong> tab, you take a look at information about your ;</p><ul><li>App</li><li>Operating System</li><li>Device</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eZJyJrijyy-kE5dTXYnUDg.png" /><figcaption>Information tab</figcaption></figure><p>In <strong>“Search by user” </strong>tab, you will find out some outputs about crash’s ;</p><ul><li>Occuring time,</li><li>User ID,</li><li>Event type,</li><li>Problems</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2UQrV1ZFEj7WEIj27oLv2Q.png" /></figure><h3>Customizing a Crash Report</h3><p>if you want , you can create your own crash report by customizing these red marked area parameters.So that your analyz will be more efficient and understandable.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/837/1*IKONU8gFgSTlfdQNfbg2GA.png" /><figcaption>customizing own crash report</figcaption></figure><h3><strong>FAQ’s</strong></h3><p><strong>Q:</strong>Can I get export the all crash reports from AppGallery Connect ?<br><strong>A:</strong>Yes sure, you can download as report <strong>.csv</strong> format in your own AGC crash page.</p><p><strong>Q:</strong>Can I see through AGC that my application has been crashed for whatever reason?<br><strong>A:</strong>Yes you can , clicking on through Problems tab, you will see 4 different tab named as Stack, Logs, Status and Information, each tab will give you different solution about what you are looking for</p><p><strong>Q:</strong>Why can’t ı see the crash report immediately in AGC ,when I run the test in my app ? Is there any duration to see and how long data is stored ?<br><strong>A:</strong>The reflection of the test report to you is at least 1 minute on average, and this data provides you with the results of <strong>hourly</strong>, <strong>24-hour</strong> and <strong>7-day</strong>, <strong>30-day</strong> and<strong> 90-day</strong> data.</p><p>We have come to the end of my article, I hope what I mentioned will be useful to you, see you in my next article, I wish you all have a nice day…</p><h4><strong>References</strong></h4><p><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-crash-introduction">Document</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=854d26a69894" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers/agc-crash-service-android-854d26a69894">AGC- Crash Service (Android)</a> was originally published in <a href="https://medium.com/huawei-developers">Huawei Developers</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Application Performance Management(APM)]]></title>
            <link>https://medium.com/huawei-developers/application-performance-management-apm-234f489397ca?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/234f489397ca</guid>
            <category><![CDATA[apm]]></category>
            <category><![CDATA[agc]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[hms]]></category>
            <category><![CDATA[app-performance]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Thu, 05 Nov 2020 08:25:57 GMT</pubDate>
            <atom:updated>2020-11-05T08:25:57.393Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/983/1*QnfbzFZ6m1H4AGwtujKebw.png" /><figcaption><strong>APM</strong></figcaption></figure><h3>What is the APM ?</h3><p><strong>Application Performance Management (APM) </strong>generally provides important services for web and cloud services, with features such as monitoring and managing software in terms of accessibility and performance, detecting problems that cause interruptions in accessing especially critical applications.</p><h3>APM features and Key Functions</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/561/1*TAvI_-atMyXcV7SljfBCDQ.png" /><figcaption><strong>Key Functions of APM</strong></figcaption></figure><p><strong>APM </strong>has some features that its user’s can handle facing problems easily, such as;</p><ul><li>A collecting key app performance data automatically</li><li>Discovery modelling and display</li><li>Deep-dive monitoring in an application context</li><li>Analytics of data</li><li>•Discovery modelling and display User-defined transaction profiling</li></ul><h3>Working Principle of APM</h3><p>App Performance Management (APM) of HUAWEI <a href="https://id1.cloud.huawei.com/CAS/portal/loginAuth.html?validated=true&amp;themeName=red&amp;service=https%3A%2F%2Foauth-login1.cloud.huawei.com%2Foauth2%2Fv2%2Flogin%3Faccess_type%3Doffline%26client_id%3D6099200%26display%3Dpage%26flowID%3D7bfc947f-0739-495b-bf15-ee93bf3d845b%26h%3D1603195509.8400%26lang%3Den-us%26redirect_uri%3Dhttps%253A%252F%252Fdeveloper.huawei.com%252Fconsumer%252Fen%252Fservice%252Fjosp%252Fagc%252FhandleLogin.html%26response_type%3Dcode%26state%3D7222394%26v%3D5b8aefeec8a01e5f0f0f86bf9624645d791c5395e6801390dcea3fc3c9b98f51&amp;loginChannel=89000000&amp;reqClientType=89&amp;lang=en-us&amp;clientID=6099200"><strong>AppGallery Connect </strong></a>provides minute-level app performance monitoring capabilities. You can view and analyze app performance data collected by APM in AppGallery Connect to comprehensively understand online performance of apps in real time, helping you quickly and accurately rectify app performance problems and continuously improve users experience.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cpL6EeueP9e-xBmZp94mGQ.png" /><figcaption><strong>Schema of APM working principle</strong></figcaption></figure><h3>How to Use APM in HMS ?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*efCunjs479QM8nDAOwc-wA.png" /><figcaption><strong>APM in HMS</strong></figcaption></figure><h4>Integrating the AppGallery Connect SDK</h4><p>Before integrating the APM SDK, be sure of your app has been integrated with <strong>AppGallery Connect SDK</strong> and<strong> AppGallery Connect plug-in. </strong>For details, please check that <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-get-started"><strong>Getting Started with Android</strong></a> page.</p><h4>Integrating the APM SDK</h4><p><strong>1-</strong> In the development environment , we need <strong>build.gradle </strong>file which is APM SDK dependency to the <strong>app-level.</strong></p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/86d6a7ca826c4d57d8966c579824ed81/href">https://medium.com/media/86d6a7ca826c4d57d8966c579824ed81/href</a></iframe><p><strong>2-</strong> Please add the following items to app-level <strong>obfuscation configurations</strong>:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ace03c6b850ec4f6e9401ad4a433917e/href">https://medium.com/media/ace03c6b850ec4f6e9401ad4a433917e/href</a></iframe><p><strong>3- </strong>If you are using <strong>AndResGuard</strong>, add the following to its trust-list to prevent obfuscation:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/00f21107fa13c375767ca00d1f4b124c/href">https://medium.com/media/00f21107fa13c375767ca00d1f4b124c/href</a></iframe><p><strong>4-</strong> If your app uses the <strong>AndroidX </strong>class library, you should add the following configuration to <strong>gradle.properties, </strong>by this way, the <strong>APM </strong>will be adapting to <strong>AndroidX </strong>automatically.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d2c18f74e75371fd4cd425b8a60e6ac4/href">https://medium.com/media/d2c18f74e75371fd4cd425b8a60e6ac4/href</a></iframe><h4>Integrating the APM Plug-in</h4><p><strong>1- Build.gradle</strong> file needs to get added to <strong>APM </strong>plug-in to the app-level.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/15be20d8e64b1dba040554db0a49f1b2/href">https://medium.com/media/15be20d8e64b1dba040554db0a49f1b2/href</a></iframe><p><strong>2- </strong>Add the APM plug-in to the <strong>project-level</strong> <strong>build.gradle</strong> file.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/61a40f72894ac9d0653a706c87312b76/href">https://medium.com/media/61a40f72894ac9d0653a706c87312b76/href</a></iframe><p>After completing the integration process, with the below table step your application will be compiled again.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/292/1*FYQXgiOg7bXUSjll9OxmbA.png" /><figcaption><strong>Build project</strong></figcaption></figure><p>After whole steps completed, Integration operation is ended for APM. As the next step, we are going to analyze our data on performance monitoring screen .Lastly we can complete with APM performance data by displaying results.</p><h4>How to Enable App performance management</h4><p>Now , you are going to know , how to enable app performance management step by step.</p><p><strong>1- </strong>Firstly, after sign-in with your <strong>Huawei Developer </strong>account, go by slipping <strong>App Services →Huawei AppGallery → My apps.</strong></p><p><strong>2- </strong>On that screen choose your own app ,then on bottom left side you will see <strong>Quality →APM</strong> as the below</p><p><strong>3- </strong>Last but not least, it should be activated by clicking on <strong>“Enable”</strong> button as shown below table.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vIwH-uZtqpo9dYXmwh3vMg.png" /><figcaption><strong>Enable button for APM on AppGallery Connect</strong></figcaption></figure><p><strong>Note:</strong> While enabling APM, you need to settle the storage location. After that configuration in <strong>agconnect-services.json</strong> is automatically updated according to this.<br>If you have set the data storage location while enabling APM, you need to download <strong>agconnect-services.json</strong> again and integrate it into your project after the service is activated.</p><p>In the below table, you can check if the application performance data is properly displayed, but there may be a delay of 15 minutes.<br>You may not be able to view data simultaneously, so constantly refresh your page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GXopb2LBTchwCIEE9GAGLQ.png" /><figcaption><strong>APM Overview</strong></figcaption></figure><p>If the page display the data incorrectly or page appears as empty for a long time, please check <strong>“</strong><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-viewlog"><strong>Viewing Debug Logs</strong></a><strong>” </strong>out page.</p><h3>Viewing and Analyzing App Performance Data</h3><h4>App launch duration</h4><p>In this section , you are going to find out duration between the time when the app is launched in the background and that when the first page is displayed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GfoQjdnxZ-1nNwuEDxYLJA.png" /><figcaption><strong>App Launch Duration</strong></figcaption></figure><p>This function monitors the app launch duration, so that you can understand the app launch performance in a timely manner. It uses the app launch duration as an indicator and calculates the percentile value of the app launch duration to display the overall distribution of the app launch duration.</p><p>In the below table, by clicking <strong>App analysis →App launch duration →View Details” </strong>you can reach more information about it or you can view the same schema by following <strong>Overview →Launch Duration(Indicator Overview) →Details </strong>steps.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wUkLPS2AXokvP15Eb_g1tw.png" /><figcaption><strong>App Launch Duration 2</strong></figcaption></figure><p>Consequently, While following <strong>Overview →Launch duration</strong> screen you are going to investigate about;</p><ul><li>Between which hours Application is started averagely,</li><li>% of launch speed in application usage,</li><li>According to the application version analyzes are available by starting time,</li><li>Average start time</li></ul><p>In the below table, by clicking <strong>App analysis →App launch duration →View Details” </strong>shows the slow frame rates in different dimensions (such as the version number, country/region, device model, level-1 region, system version, carrier, and network). The dimensions can be sorted by slow frame rate, number of samples, or number of sessions. When statistics are collected by version, the chart displays the slow frame rates of all versions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ILhtRCf-ts4xXoQVp6Z78A.png" /></figure><p>Moreover, while clicking <strong>“View Sessions” </strong>on the right side you are going to come upon below table.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xwQuKfD0DgLPm2aeRH3Nrg.png" /><figcaption><strong>Session List 1</strong></figcaption></figure><p>You can reach information such as Application starting time , how much time that needed , which smartphone model is used during this time, connection from which country ,Network are used.</p><p>In addition, There is animated cursor on graph so you can navigate on the graphs and examine numerical data about all units.</p><p>Lastly, if you click <strong>“View Details” </strong>under <strong>“Operation” </strong>column you will see <strong>“Session List” </strong>page in the below table. In this section also, you can get that knowledge;</p><ul><li>CPU usage duration,</li><li>Memory usage,</li><li>Information about device</li><li>Network data</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PbosHZpGm4-Htfk30r57iA.png" /><figcaption><strong>Session List 2</strong></figcaption></figure><h4>Background and Foreground Activity Performance Data</h4><p><strong>Background activity duration</strong>: duration from the time when the last activity calls the <strong>onStop()</strong> method before an app is switched to the background to the time when the first activity calls the <strong>onResume()</strong> method after the app is switched to the foreground.</p><p><strong>Foreground activity duration</strong>: duration from the time when the first activity calls the <strong>onResume()</strong> method after an app is launched or switched to the foreground to the time when the last activity calls the <strong>onStop()</strong> method before the app is switched to the background.</p><p>You can reach below table following <strong>Overview →App Analysis → App foreground or background activity</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3kYs9Pm0px2SLtam5SfQWA.png" /><figcaption><strong>Background Activity</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*siwJ0MYwLfNHi0dagrCtYg.png" /><figcaption><strong>Foreground Activity</strong></figcaption></figure><p><strong>1-</strong> <strong>In top left ,</strong>shows the foreground activity duration distribution. When you move the cursor, the specified frontend activity duration and its percentile are displayed.</p><p><strong>2-</strong> <strong>In top right,</strong> shows the foreground activity duration distribution by time. When you move the cursor, the median frontend activity duration and durations of 5th and 95th percentiles at the specified time points are displayed.</p><p><strong>3- In bottom left,</strong> shows the foreground activity duration distribution by version. When you point to a bar of a version, the median frontend activity duration and durations of 5th and 95th percentiles, number of samples, and number of sessions are displayed.</p><h4>Network Analysis</h4><p>Performance data includes the duration between the time when an app sends a network request to your server and the time when the response from your server is complete, request status code, request load, and response load.</p><p><strong>Network Request Indicator Definition</strong></p><ul><li><strong>URL</strong>: network request URL .</li><li><strong>Number of requests</strong>: the number of times a request URL is invoked.</li><li><strong>Request duration</strong>: interval between the time when an app sends a request and the time when the app receives a response from the server.</li><li><strong>Success rate</strong>: percentage of requests whose status code is 2xx or 3xx to the total number of requests.</li><li><strong>Request load size</strong>: number of bytes of the network payload for upload in an app.</li><li><strong>Response load size</strong>: number of bytes of the network payload to be downloaded in an app.</li></ul><p>You can get below page following <strong>Overview </strong>→<strong>Network Analysis </strong>steps.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vgtLUOVIN50Un4jHiOjfzg.png" /><figcaption><strong>Network Analysis</strong></figcaption></figure><p>In the above table , <strong>APM </strong>monitors <strong>HTTP/HTTPS</strong> network requests initiated by the <strong>OkHttp</strong>, <strong>URLConnection</strong>, and <strong>ApacheHttpClient </strong>and clusters data of the same type of network requests by matching URL clustering rules, helping you understand the network request performance trend and detect network problems in a timely manner.</p><p>Please click on “<strong>View details” </strong>under “<strong>operation</strong>” column for displaying network request. The details page contains the <strong>Request duration</strong> and <strong>Request success rate</strong> tab pages.</p><h4>Request duration</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Yx2VbIVJ3z8AkOEgbz8cCw.png" /><figcaption><strong>Request Duration</strong></figcaption></figure><p><strong>1-</strong> <strong>In top left, </strong>figure shows the distribution of network request durations. When you move the cursor, the percentile of the specified network request duration is displayed. For example, the median network request duration is 1.6 s, indicating that 50% of network request durations are less than or equal to 1.6s.</p><p><strong>2-</strong> <strong>In top right,</strong> figure shows the network request duration distribution by version. When you point to a bar of a version, the median network request duration and durations of 5th and 95th percentiles, number of samples, and number of sessions are displayed.</p><p><strong>3- In bottom left,</strong> figure shows the network request duration distribution by version. When you point to a bar of a version, the median network request duration and durations of 5th and 95th percentiles, number of samples, and number of sessions are displayed.</p><h4>Request Success Rate</h4><p>The following schema describes <strong>Request success rate</strong> page that;</p><p><strong>1-</strong> <strong>In top left, </strong>Average network request success rate, that is, <strong>100%</strong>.</p><p><strong>2-</strong> <strong>In top right, </strong>the rate of top 10 status codes of network requests, the rate of response code <strong>200 </strong>is <strong>100%</strong>.</p><p><strong>3-</strong> <strong>In bottom left, </strong>the network request success rate distribution by time. the network request success rate at 08:00 on October 5 is <strong>100%</strong>.</p><p><strong>4-</strong> <strong>In bottom right, </strong>the network request success rate distribution by version. When you point to a bar of a version, the network request success rate of the corresponding version is displayed. In the figure, the network request success rate of version <strong>1.0 data </strong>is 100%.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4VGWiBeANQL5gSq6bD0wQQ.png" /><figcaption><strong>Request Success Rate</strong></figcaption></figure><h3>Viewing ANR Data</h3><p><strong>ANR</strong> is a mechanism that ,UI thread of an Android app is blocked for too long , <strong>“Application Not Responding” (ANR) </strong>error is triggered. In this situation APM service records basic key information when an ANR occurs.</p><p>If the app is in the foreground, the system displays a dialog to the user just like pop-up menu and gives the user opportunity to force quit the app.</p><p><strong>App ANR Indicators</strong></p><ul><li><strong>Occurrences</strong>:ANR problem occurence time within a specified time range.</li><li><strong>Affected users</strong>: number of users affected by ANR problems within a specified time range.</li><li><strong>ANR-affected user rate</strong>: total number of app users within a specified time range and rate of users.</li><li><strong>ANR-affected user rate trend</strong>: rate of ANR occurrences to app launch times within a specified time range, that is, the probability that an ANR problem occurs during a single app launch.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cYwlt2iX0jm_zut4K55FYQ.png" /><figcaption><strong>ANR Analysis</strong></figcaption></figure><p>In above general <strong>ANR analysis </strong>screen, In here you can find all data information about ANR such as;</p><ul><li>Occurrences,</li><li>Affected users,</li><li>ANR-affected user rate,</li><li>ANR affected user rate trend</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/578/1*pprwzpyMxHSvbFIHXR3sBQ.png" /><figcaption><strong>Top 5 problems</strong></figcaption></figure><p>Top left on the page, especially you will see data <strong>“Top 5 problems in last 24 hours</strong>” with the red zone area.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DAOsOl1l68aw4ydXrZF7Mw.png" /><figcaption><strong>ANR-affected user rate trend</strong></figcaption></figure><p>In <strong>ANR-affected user rate trend </strong>if you wish you can examine in detail by filtering tab on the right ,according to ;</p><ul><li>By time,</li><li>By app version,</li><li>By OS version,</li><li>By device model</li></ul><p>In lowest part on page , at “<strong>Problems (by affected user rate)” </strong>you can some data about affected users by ;</p><ul><li>Affected users in last 24 hours,</li><li>Affected user rate in last 24 hours,</li><li>Occurences,</li><li>Affected users,</li><li>First occured &amp; last occured time</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2zUpYqEFVuzojRgH-c820g.png" /><figcaption><strong>Problems (by affected user rate)</strong></figcaption></figure><p>When you click on <strong>“View details” </strong>under <strong>“Operation”</strong> tab. You will find the opportunity to analyze graphically in more detail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MIa58NVrQ99PzORfCBbJfQ.png" /><figcaption><strong>ANR analysis list</strong></figcaption></figure><p>In the bottom of the page you will see the <strong>“records”</strong> section. In this part you can find various information such as;</p><ul><li>ID,</li><li>First occured,</li><li>App version,</li><li>OS version,</li><li>Device Model,</li><li>Operation</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5KJVxxIsr0rc_bfMqjyLNQ.png" /><figcaption><strong>Records</strong></figcaption></figure><p>In <strong>“Operation” </strong>tab , while clicking on <strong>“View details” </strong>this time you will come across enormous data page and you will find out in detail;</p><ul><li>Device information,</li><li>System information,</li><li>App information</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6_tQuSrvGAFEKFjG3yaXpQ.png" /><figcaption><strong>Information</strong></figcaption></figure><p>Except those ,This page displays ;</p><ul><li>Main thread steak info,</li><li>Other thread steak info,</li><li>System logs,</li><li>ANR info</li></ul><p>when an ANR problem occurs, helping you comprehensively understand various information when an ANR problem occurs in your app.</p><p>In addition, APM provides the record export function. You can click on “<strong>Export”</strong> to export all information on the page for comparison and analysis.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XmLdslI52pPTwxwZ2ucu9Q.png" /><figcaption><strong>Log Info</strong></figcaption></figure><p>You can find out how to disable APM in your application with that <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-stopapms">link</a>.</p><p><strong>Here is the some FAQ’s which I create my own while investigating on APM.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/80/1*4GCMSTfckEadlwZOamEhjQ.png" /></figure><h3>FAQ’s</h3><p><strong>Q: </strong>Does the APM provide to show the user’s smartphone information (such as system version, Model, Memory, Carrier, OS version, CPU model etc) ?<br><strong>A:</strong> Yes it does, the APM makes it possible.</p><p><strong>Q:</strong> Does the APM supported about CPU usage duration ,how much CPU is used by system and user ?<br><strong>A:</strong> Yes the APM provides information about CPU usage duration ,both system and user.</p><p><strong>Q:</strong> Can the user see, how much memory is used during APM is actively working ? <br><strong>A: </strong>Yes the user can instantly view the memory usage.</p><p><strong>Q:</strong> Can users get information about how long the application they run on their device runs in the foreground and background by using APM?<br><strong>A: </strong>Of course, Background-Foreground activity duration time is shown to user as start time period and total duration time.</p><p><strong>Q: </strong>What frameworks does APM SDK support and give benefit for network request monitoring?<br><strong>A:</strong> Via the linked URLConnection and OkHttp frameworks is shared start-end time, required time for connection, Status code, Request load, response load, download speed with the user in detail.</p><p><strong>Q:</strong> Does the APM SDK only supports Android applications ?<br><strong>A:</strong> The APM SDK support for multiple platforms such as HTML5 Page Analysis, the iOS platform, the web system, Network hijacking analysis as well as Android platform.</p><p><strong>Q:</strong> What if network data is not responding, how can I check out that where the main defect ?<br><strong>A:</strong> In the ANR analysis section presented by APM for the solution of the main problem, the number of users affected by this situation, their rate and detailed information in graphical terms are provided to us. The application automatically triggers <strong>ANR </strong>and in case it fails to get an answer, it ensures the detection of the problem with stored system log files and ANR info.</p><p><strong>I hope this is a useful article for you, see you in my next post, goodbye…</strong></p><p><strong>References</strong></p><p><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-introduction">https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-introduction</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=234f489397ca" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers/application-performance-management-apm-234f489397ca">Application Performance Management(APM)</a> was originally published in <a href="https://medium.com/huawei-developers">Huawei Developers</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Uygulama Performans Yönetimi (APM)]]></title>
            <link>https://medium.com/huawei-developers-tr/uygulama-performans-y%C3%B6netimi-apm-cb4e450a0fa4?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/cb4e450a0fa4</guid>
            <category><![CDATA[agc]]></category>
            <category><![CDATA[huawei]]></category>
            <category><![CDATA[app-performance]]></category>
            <category><![CDATA[hms]]></category>
            <category><![CDATA[apm]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Thu, 05 Nov 2020 06:55:48 GMT</pubDate>
            <atom:updated>2020-11-05T13:44:04.326Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/983/1*QnfbzFZ6m1H4AGwtujKebw.png" /><figcaption><strong>APM</strong></figcaption></figure><h3>APM nedir ?</h3><p><strong>Uygulama Performans Yönetimi (APM)</strong> genel olarak, erişilebilirlik ve performans açısından yazılımları izleme ve yönetme, özellikle kritik uygulamalara erişimde kesintilere neden olan sorunları algılama gibi özelliklerle web ve bulut hizmetleri için önemli hizmetler sağlar.</p><h3><strong>APM özellikleri ve Temel İşlevler</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/561/1*TAvI_-atMyXcV7SljfBCDQ.png" /><figcaption><strong>Key Functions of APM</strong></figcaption></figure><p>APM, kullanıcılarının karşılaştığı sorunlarla kolaylıkla başa çıkabileceği bazı özelliklere sahiptir;</p><ul><li>Otomatik olarak önemli uygulama performans verilerini toplama,</li><li>Keşif modelleme ve görüntüleme,</li><li>Bir uygulama bağlamında derinlemesine izleme,</li><li>Veri analizi,</li><li>Keşif modelleme ve Kullanıcı tanımlı işlem profili oluşturma.</li></ul><h3>APM’nin Çalışma Prensibi</h3><p><strong>HUAWEI AppGallery Connect</strong>’in Uygulama Performans Yönetimi (APM), dakika düzeyinde uygulama performansı izleme yetenekleri sağlar. Uygulamaların çevrimiçi performansını gerçek zamanlı olarak kapsamlı bir şekilde anlamak için APM tarafından toplanan uygulama performansı verilerini görüntüleyebilir ve analiz edebilir, böylece uygulama performans sorunlarını hızlı ve doğru bir şekilde düzeltebilir ve kullanıcı deneyimini sürekli olarak iyileştirebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cpL6EeueP9e-xBmZp94mGQ.png" /><figcaption><strong>Schema of APM working principle</strong></figcaption></figure><h3>HMS ile APM Nasıl Kullanılır?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*efCunjs479QM8nDAOwc-wA.png" /><figcaption><strong>APM in HMS</strong></figcaption></figure><h4>AppGallery Connect SDK’yı entegre etme</h4><p>APM SDK’yı entegre etmeden önce, uygulamanızın AppGallery Connect SDK ve AppGallery Connect eklentisiyle entegre edildiğinden emin olun. Ayrıntılar için lütfen <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-get-started"><strong>Android’e Başlarken sayfasına</strong></a> bakın.</p><h4>APM SDK’yı entegre etme</h4><p><strong>1-</strong> Geliştirme ortamında, <strong>app-level</strong> APM SDK bağımlılığı olan <strong>build.gradle</strong> dosyasına ihtiyacımız var.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/86d6a7ca826c4d57d8966c579824ed81/href">https://medium.com/media/86d6a7ca826c4d57d8966c579824ed81/href</a></iframe><p><strong>2-</strong> Lütfen aşağıdaki öğeleri uygulama düzeyinde gizleme yapılandırmalarına ekleyin:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ace03c6b850ec4f6e9401ad4a433917e/href">https://medium.com/media/ace03c6b850ec4f6e9401ad4a433917e/href</a></iframe><p><strong>3-</strong> <strong>AndResGuard </strong>kullanıyorsanız, şaşırtmayı önlemek için aşağıdakileri güven listesine ekleyin:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/00f21107fa13c375767ca00d1f4b124c/href">https://medium.com/media/00f21107fa13c375767ca00d1f4b124c/href</a></iframe><p><strong>4-</strong> Uygulamanız <strong>AndroidX </strong>sınıf kitaplığını kullanıyorsa, aşağıdaki yapılandırmayı <strong>gradle.properties</strong> dosyasına eklemelisiniz, bu şekilde <strong>APM AndroidX</strong>’e otomatik olarak adapte olacaktır.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d2c18f74e75371fd4cd425b8a60e6ac4/href">https://medium.com/media/d2c18f74e75371fd4cd425b8a60e6ac4/href</a></iframe><h4>APM Eklentisini Entegre Etme</h4><p><strong>1-</strong> <strong>Build.gradle</strong> dosyasının uygulama düzeyinde <strong>APM </strong>eklentisine eklenmesi gerekir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/15be20d8e64b1dba040554db0a49f1b2/href">https://medium.com/media/15be20d8e64b1dba040554db0a49f1b2/href</a></iframe><p><strong>2-</strong> <strong>APM </strong>eklentisini proje düzeyindeki <strong>build.gradle</strong> dosyasına ekleyin.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/61a40f72894ac9d0653a706c87312b76/href">https://medium.com/media/61a40f72894ac9d0653a706c87312b76/href</a></iframe><p>Entegrasyon işlemi tamamlandıktan sonra aşağıdaki tablo adımı ile uygulamayı tekrar deryelebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/292/1*FYQXgiOg7bXUSjll9OxmbA.png" /><figcaption><strong>Build project</strong></figcaption></figure><p>Tüm adımlar tamamlandıktan sonra APM için Entegrasyon işlemi sonlandırılır. Bir sonraki adım olarak verilerimizi performans izleme ekranında analiz edeceğiz.Son olarak sonuçları görüntüleyerek APM performans verilerini inceleyebiliriz.</p><h4>Uygulama performans yönetimi nasıl etkinleştirilir ?</h4><p>Şimdi, uygulama performans yönetimini adım adım nasıl etkinleştireceğinizi öğreneceksiniz.</p><p><strong>1-</strong> Öncelikle, Huawei Geliştirici hesabınızla oturum açtıktan sonra, <strong>App Services →Huawei AppGallery → My apps</strong> kaydırarak devam edin.</p><p><strong>2-</strong> Bu ekranda kendi uygulamanızı seçin, ardından sol alt tarafta <strong>Quality →APM </strong>aşağıdaki gibi göreceksiniz.</p><p><strong>3-</strong> Son olarak aşağıdaki tabloda gösterildiği gibi <strong>“Enable”</strong> butonuna tıklanarak aktif hale getirilmelidir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vIwH-uZtqpo9dYXmwh3vMg.png" /><figcaption><strong>Enable button for APM on AppGallery Connect</strong></figcaption></figure><p><strong>Not:</strong> <strong>APM’yi </strong>etkinleştirirken, depolama konumunu belirlemeniz gerekir. <strong>Agconnect-services.json</strong>’daki bu konfigürasyondan sonra buna göre otomatik olarak güncellenir.</p><p>APM’yi etkinleştirirken veri depolama konumunu ayarladıysanız, <strong>agconnect-services.json</strong> dosyasını tekrar indirmeniz ve hizmet etkinleştirildikten sonra projenize entegre etmeniz gerekir.</p><p>Aşağıdaki tabloda, uygulama performans verilerinin düzgün görüntülenip görüntülenmediğini kontrol edebilirsiniz, ancak 15 dakikalık bir gecikme olabilir.<br>Verileri aynı anda görüntüleyemeyebilirsiniz, bu nedenle sayfanızı sürekli yenileyin.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GXopb2LBTchwCIEE9GAGLQ.png" /><figcaption><strong>APM Overview</strong></figcaption></figure><p>Sayfa verileri yanlış gösteriyorsa veya sayfa uzun bir süre boş görünüyorsa, lütfen <strong>“</strong><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-viewlog"><strong>Hata Ayıklama Günlüklerini Görüntüleme</strong></a><strong>”</strong> sayfasını kontrol edin.</p><h3>Uygulama Performans Verilerini Görüntüleme ve Analiz Etme</h3><h4>App launch duration</h4><p>Bu bölümde, uygulamanın arka planda başlatıldığı zaman ile ilk sayfanın görüntülendiği zaman arasındaki süreyi öğreneceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GfoQjdnxZ-1nNwuEDxYLJA.png" /><figcaption><strong>App Launch Duration</strong></figcaption></figure><p>Bu işlev, uygulama başlatma süresini izler, böylece uygulama başlatma performansını zamanında anlayabilirsiniz. Gösterge olarak uygulama başlatma süresini kullanır ve uygulama başlatma süresinin genel dağılımını görüntülemek için uygulama başlatma süresinin yüzde değerini hesaplar.</p><p>Aşağıdaki tabloda,<strong>App analysis →App launch duration →View Details”</strong> e tıklayarak bununla ilgili daha fazla bilgiye ulaşabilir veya aynı şemayı <strong>Overview →Launch Duration(Indicator Overview) →Details</strong> adımlarını takip ederek görüntüleyebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wUkLPS2AXokvP15Eb_g1tw.png" /><figcaption><strong>App Launch Duration 2</strong></figcaption></figure><p>Sonuç olarak, <strong>Overview →Launch duration</strong> ekranını takip ederken şunlar hakkında inceleme yapacaksınız;</p><ul><li>Ortalama olarak hangi saatler arasında uygulamaya başlandığı,</li><li>Uygulama kullanımında başlatma hızının yüzdesi,</li><li>Uygulama sürüm analizlerine göre başlangıç ​​saatine göre mevcuttur,</li><li>Ortalama başlangıç ​​zamanı</li></ul><p>Aşağıdaki tabloda, <strong>App analysis →App launch duration →View Details </strong>e tıkladığınızda, farklı boyutlardaki yavaş kare hızları (sürüm numarası, ülke / bölge, cihaz modeli, seviye-1 bölge, sistem sürümü, operatör ve Boyutlar yavaş kare hızına, örnek sayısına veya oturum sayısına göre sıralanabilir.İstatistikler sürüme göre toplandığında, grafik tüm sürümlerin yavaş kare hızlarını gösterir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ILhtRCf-ts4xXoQVp6Z78A.png" /></figure><p>Ayrıca sağ tarafta bulunan <strong>“View Sessions”</strong> ye tıklarken aşağıdaki tabloya geleceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xwQuKfD0DgLPm2aeRH3Nrg.png" /><figcaption><strong>Session List 1</strong></figcaption></figure><p>Uygulama başlama saati, ne kadar süre gerekli olduğu, bu süre içinde hangi akıllı telefon modelinin kullanıldığı, hangi ülkeden bağlantı, Ağın kullanıldığı gibi bilgilere ulaşabilirsiniz.</p><p>Ek olarak, grafikte gezinebilmeniz ve tüm birimlerle ilgili sayısal verileri inceleyebilmeniz için grafik üzerinde animasyonlu imleç bulunmaktadır.</p><p>Son olarak, <strong>“Operation”</strong> sütunu altında <strong>“View Details”</strong> yi tıklarsanız, aşağıdaki tabloda <strong>“Session List”</strong> sayfasını göreceksiniz. Bu bölümde de şu bilgileri edinebilirsiniz;</p><ul><li>CPU kullanım süresi,</li><li>Hafıza kullanımı,</li><li>Cihazla ilgili bilgiler,</li><li>Ağ verileri</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PbosHZpGm4-Htfk30r57iA.png" /><figcaption><strong>Session List 2</strong></figcaption></figure><h4>Background ve Foreground Activity Performans Verileri</h4><p><strong>Arka plan etkinlik süresi:</strong> Bir uygulama arka plana geçmeden önce son etkinliğin <strong>onStop()</strong> yöntemini çağırmasından, ilk etkinliğin uygulama ön plana geçtikten sonra <strong>onResume()</strong> yöntemini çağırmasına kadar geçen süre.</p><p><strong>Ön plan etkinlik süresi:</strong> Bir uygulama başlatıldıktan veya ön plana geçtikten sonra ilk etkinliğin <strong>onResume()</strong> yöntemini çağırdığı zamandan, uygulama arka plana geçmeden önceki son etkinliğin <strong>onStop() </strong>yöntemini çağırmasına kadar geçen süre.</p><p>Aşağıdaki tabloya <strong>Overview →App Analysis → App foreground or background activity</strong> takip ederek ulaşabilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3kYs9Pm0px2SLtam5SfQWA.png" /><figcaption><strong>Background Activity</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*siwJ0MYwLfNHi0dagrCtYg.png" /><figcaption><strong>Foreground Activity</strong></figcaption></figure><p><strong>1-</strong> <strong>Sol üstte</strong>, ön plan etkinlik süresi dağılımını gösterir. İmleci hareket ettirdiğinizde, belirtilen ön uç etkinlik süresi ve yüzdelik dilim görüntülenir.</p><p><strong>2- Sağ üstte</strong>, zamana göre ön plan etkinlik süresi dağılımını gösterir. İmleci hareket ettirdiğinizde, belirtilen zaman noktalarında medyan ön uç aktivite süresi ve 5. ve 95. yüzdelik dilimlerin süreleri görüntülenir.</p><p><strong>3-</strong> <strong>Sol altta</strong>, sürüme göre ön plan etkinlik süresi dağılımını gösterir. Bir sürümün bir çubuğunu işaret ettiğinizde, medyan ön uç etkinlik süresi ve 5. ve 95. yüzdelik dilimler, örnek sayısı ve oturum sayısı görüntülenir.</p><h4>Network Analysis</h4><p>Performans verileri, bir uygulamanın sunucunuza bir ağ isteği gönderdiği zaman ile sunucunuzdan yanıtın tamamlandığı zaman, istek durum kodu, istek yükü ve yanıt yükü arasındaki süreyi içerir.</p><h4>Ağ Talep Göstergesi Tanımı</h4><p><strong>URL:</strong> ağ istek URL’si.<br><strong>İstek sayısı:</strong> bir istek URL’sinin çağrılma sayısı.<br><strong>İstek süresi:</strong> Bir uygulamanın bir istek gönderdiği zaman ile uygulamanın sunucudan bir yanıt aldığı zaman arasındaki aralık.<br><strong>Başarı oranı:</strong> durum kodu 2xx veya 3xx olan isteklerin toplam istek sayısına oranı.<br><strong>İstek yükleme boyutu:</strong> Bir uygulamaya yüklemek için ağ yükünün bayt sayısı.<br><strong>Yanıt yükleme boyutu: </strong>Bir uygulamada indirilecek ağ yükünün bayt sayısı.</p><p><strong>Overview </strong>→<strong>Network Analysis</strong> adımlarını takip ederek aşağıdaki sayfaya ulaşabilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vgtLUOVIN50Un4jHiOjfzg.png" /><figcaption><strong>Network Analysis</strong></figcaption></figure><p>Yukarıdaki tabloda <strong>APM</strong>, <strong>OkHttp, URLConnection</strong> ve<strong> ApacheHttpClient </strong>tarafından başlatılan <strong>HTTP / HTTPS</strong> ağ isteklerini izler ve URL kümeleme kurallarını eşleştirerek aynı tür ağ isteklerinin verilerini kümeler, ağ isteği performans eğilimini anlamanıza ve ağ sorunlarını tespit etmenize yardımcı olur.</p><p>Ağ talebini görüntülemek için lütfen “<strong>operation</strong>” sütununun altındaki “<strong>View details” </strong>e tıklayın. Ayrıntılar sayfası, <strong>Request duration</strong> ve <strong>Request success rate </strong>sekme sayfalarını içerir.</p><h4>Request duration</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Yx2VbIVJ3z8AkOEgbz8cCw.png" /><figcaption><strong>Request Duration</strong></figcaption></figure><p><strong>1- Sol üstteki</strong> şekil ağ istek sürelerinin dağılımını göstermektedir. İmleci hareket ettirdiğinizde, belirtilen ağ talebi süresinin yüzdelik dilimi görüntülenir. Örneğin, medyan ağ isteği süresi 1,6 saniyedir ve bu, ağ isteği sürelerinin% 50&#39;sinin 1,6 saniyeden az veya buna eşit olduğunu gösterir.<br><strong>2-</strong> <strong>Sağ üstteki </strong>şekil ağ talebi süresinin versiyona göre dağılımını göstermektedir. Bir sürümün bir çubuğunu işaret ettiğinizde, medyan ağ talebi süresi ve 5. ve 95. yüzdelik dilimler, örnek sayısı ve oturum sayısı görüntülenir.<br><strong>3-</strong> <strong>Sol alttaki</strong> şekil ağ talebi süresinin versiyona göre dağılımını göstermektedir. Bir sürümün bir çubuğunu işaret ettiğinizde, medyan ağ talebi süresi ve 5. ve 95. yüzdelik dilimler, örnek sayısı ve oturum sayısı görüntülenir.</p><h4>Request Success Rate</h4><p>Aşağıdaki şema; İstek başarı oranı sayfasını açıklar;</p><p>1- <strong>Sol üstte,</strong> Ortalama ağ isteği başarı oranı, yani <strong>% 100</strong>.<br>2- <strong>Sağ üstte,</strong> ağ isteklerinin ilk 10 durum kodu oranı, 200 kodunun yanıt oranı <strong>% 100</strong>&#39;dür.<br>3- <strong>Sol altta,</strong> ağ zamana göre başarı oranı dağılımı talep ediyor. 5 Ekim 08: 00&#39;daki ağ isteği başarı oranı <strong>% 100&#39;</strong>dür.<br>4- <strong>Sağ altta</strong>, ağ versiyona göre başarı oranı dağılımı talep ediyor. Bir sürüm çubuğuna işaret ettiğinizde, ilgili sürümün ağ isteği başarı oranı görüntülenir. Şekilde, sürüm <strong>1.0 verilerinin </strong>ağ isteği başarı oranı% 100&#39;dür.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4VGWiBeANQL5gSq6bD0wQQ.png" /><figcaption><strong>Request Success Rate</strong></figcaption></figure><h3>Viewing ANR Data</h3><p><strong>ANR</strong>, bir Android uygulamasının UI iş parçacığının çok uzun süre engellendiği, <strong>“Application Not Responding” (ANR)</strong> hatası tetiklenen bir mekanizmadır. Bu durumda APM hizmeti, bir ANR meydana geldiğinde temel anahtar bilgileri kaydeder.</p><p>Uygulama ön plandaysa, sistem kullanıcıya tıpkı açılır menü gibi bir iletişim kutusu görüntüler ve kullanıcıya uygulamadan çıkmaya zorlama fırsatı verir.</p><h4>Uygulama ANR Göstergeleri</h4><p><strong>Oluşumlar:</strong> ANR sorununun belirli bir zaman aralığında oluşma zamanı.<br><strong>Etkilenen kullanıcılar:</strong> Belirli bir zaman aralığında ANR sorunlarından etkilenen kullanıcıların sayısı.<br><strong>ANR’den etkilenen kullanıcı oranı:</strong> Belirli bir zaman aralığı ve kullanıcı oranı içindeki toplam uygulama kullanıcısı sayısı.<br><strong>ANR’den etkilenen kullanıcı oranı eğilimi:</strong> Belirli bir zaman aralığı içinde ANR oluşumlarının uygulama başlatma zamanlarına oranı, yani tek bir uygulama başlatma sırasında ANR sorununun ortaya çıkma olasılığı.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cYwlt2iX0jm_zut4K55FYQ.png" /><figcaption><strong>ANR Analysis</strong></figcaption></figure><p>Yukarıdaki genel <strong>ANR analizi</strong> ekranında, burada ANR ile ilgili tüm veri bilgilerini bulabilirsiniz;</p><ul><li>Oluşumlar,</li><li>Etkilenen kullanıcılar,</li><li>ANR’den etkilenen kullanıcı oranı,</li><li>ANR’den etkilenen kullanıcı oranı eğilimi</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/578/1*pprwzpyMxHSvbFIHXR3sBQ.png" /><figcaption><strong>Top 5 problems</strong></figcaption></figure><p>Sayfanın sol üst köşesinde, özellikle kırmızı bölge alanıyla birlikte <strong>“Top 5 problems in last 24 hours</strong>” verilerini göreceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DAOsOl1l68aw4ydXrZF7Mw.png" /><figcaption><strong>ANR-affected user rate trend</strong></figcaption></figure><p><strong>ANR-affected user rate trend</strong>‘inde dilerseniz sağdaki sekmeyi filtreleyerek detaylı olarak inceleyebilirsiniz;</p><ul><li>By time,</li><li>By app version,</li><li>By OS version,</li><li>By device model</li></ul><p>Sayfanın en alt kısmında, “<strong>Problems (by affected user rate)” </strong>altında, etkilenen kullanıcılar hakkında bazı verileri aşağıdaki şekilde bulabilirsiniz;</p><ul><li>Affected users in last 24 hours,</li><li>Affected user rate in last 24 hours,</li><li>Occurences,</li><li>Affected users,</li><li>First occured &amp; last occured time</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2zUpYqEFVuzojRgH-c820g.png" /><figcaption><strong>Problems (by affected user rate)</strong></figcaption></figure><p><strong>“Operation”</strong> sekmesinin altındaki <strong>“View details”</strong> ye tıkladığınızda. Grafiksel olarak daha detaylı analiz etme fırsatı bulacaksınız.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MIa58NVrQ99PzORfCBbJfQ.png" /><figcaption><strong>ANR analysis list</strong></figcaption></figure><p>Sayfanın altında <strong>“records”</strong>bölümünü göreceksiniz. Bu bölümde şu çeşitli verileri inceleyebileceksiniz.</p><ul><li>ID,</li><li>First occured,</li><li>App version,</li><li>OS version,</li><li>Device Model,</li><li>Operation</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5KJVxxIsr0rc_bfMqjyLNQ.png" /><figcaption><strong>Records</strong></figcaption></figure><p><strong>“Operation”</strong> sekmesinde <strong>“View details”</strong> e tıklarken bu sefer muazzam bir veri sayfasıyla karşılaşacak ve ayrıntılı olarak şunları öğreneceksiniz;</p><ul><li>Device information,</li><li>System information,</li><li>App information</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6_tQuSrvGAFEKFjG3yaXpQ.png" /><figcaption><strong>Information</strong></figcaption></figure><p>Bunların dışında, Ek olarak bu sayfa görüntülenir;</p><ul><li>Main thread steak info,</li><li>Other thread steak info,</li><li>System logs,</li><li>ANR info</li></ul><p>Bir ANR sorunu oluştuğunda, çeşitli bilgileri kapsamlı bir şekilde anlamanıza yardımcı olur.</p><p>Buna ek olarak APM, kayıt dışa aktarma işlevi sağlar. Karşılaştırma ve analiz için sayfadaki tüm bilgileri dışa aktarmak için “<strong>Export”</strong> düğmesine tıklayabilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XmLdslI52pPTwxwZ2ucu9Q.png" /><figcaption><strong>Log Info</strong></figcaption></figure><p>Bu <a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-stopapms">bağlantı</a> ile uygulamanızda APM’yi nasıl devre dışı bırakacağınızı öğrenebilirsiniz.</p><p><strong>APM konusu hakkında araştırırken kendim oluşturduğum bazı SSS’ler.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/80/1*4GCMSTfckEadlwZOamEhjQ.png" /></figure><h3>SSS</h3><p><strong>S:</strong> APM, kullanıcının akıllı telefon bilgilerini (sistem sürümü, Model, Bellek, Taşıyıcı, İşletim Sistemi sürümü, CPU modeli vb.) Göstermeyi sağlıyor mu?<br><strong>C:</strong> Evet, APM bunu mümkün kılıyor.</p><p><strong>S:</strong> APM, CPU kullanım süresi, sistem ve kullanıcı tarafından ne kadar CPU kullanıldığını destekliyor mu?<br><strong>C:</strong> Evet, APM hem sistem hem de kullanıcı için CPU kullanım süresi hakkında bilgi sağlar.</p><p><strong>S:</strong> APM aktif olarak çalışırken ne kadar bellek kullanıldığını kullanıcı görebilir mi?<br><strong>C: </strong>Evet, kullanıcı bellek kullanımını anında görüntüleyebilir.</p><p><strong>S:</strong> Kullanıcılar, APM kullanarak cihazlarında çalıştırdıkları uygulamanın ön planda ve arka planda ne kadar süreyle çalıştığı hakkında bilgi alabilir mi?<br><strong>C:</strong> Elbette, Arka Plan-Ön Plan etkinlik süresi, kullanıcıya başlangıç ​​zamanı ve toplam süre olarak gösterilir.</p><p><strong>S: </strong>APM SDK hangi çerçeveleri destekler ve ağ istek izleme için fayda sağlar?<br><strong>C:</strong> Bağlantılı URLConnection ve OkHttp çerçeveleri aracılığıyla başlangıç-bitiş zamanı, bağlantı için gerekli süre, Durum kodu, İstek yükü, yanıt yükü, indirme hızı vb. Ayrıntılı olarak kullanıcıyla paylaşılır.</p><p><strong>S:</strong> APM SDK yalnızca Android uygulamalarını mı destekliyor?<br><strong>C:</strong> APM SDK; HTML5 Sayfa Analizi, iOS platformu, web sistemi, Ağ korsanlığı analizi ve Android platformu gibi birden çok platformu destekler.</p><p><strong>S: </strong>Ya ağ verileri yanıt vermiyorsa, ana sorunun nerede olduğunu nasıl kontrol edebilirim?<br><strong>C:</strong> APM’nin ana sorunun çözümü için sunduğu ANR analizi bölümünde, bu durumdan etkilenen kullanıcı sayıları, oranları ve grafiksel olarak detaylı bilgiler tarafımıza verilmektedir. Uygulama otomatik olarak ANR’yi tetikler ve bir cevap alamaması durumunda, saklanan sistem günlük dosyaları ve ANR bilgileriyle sorunun tespit edilmesini sağlar.</p><p><strong>Bu yazının sizin için çok faydalı olacağını umuyorum, bir sonraki yazımda görüşmek üzere, hoşçakalın…</strong></p><p><strong>Referanslar</strong></p><p><a href="https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-introduction">https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-apms-introduction</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cb4e450a0fa4" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers-tr/uygulama-performans-y%C3%B6netimi-apm-cb4e450a0fa4">Uygulama Performans Yönetimi (APM)</a> was originally published in <a href="https://medium.com/huawei-developers-tr">Huawei Developers - Türkiye</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Implementation of HUAWEI Computer Graphics Kit and Introduction on Unity]]></title>
            <link>https://medium.com/huawei-developers/implementation-of-huawei-computer-graphics-kit-and-introduction-on-unity-d1474112c1f9?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/d1474112c1f9</guid>
            <category><![CDATA[vulkan]]></category>
            <category><![CDATA[computer-graphics]]></category>
            <category><![CDATA[huawei-mobile-service]]></category>
            <category><![CDATA[hms]]></category>
            <category><![CDATA[unity]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Mon, 05 Oct 2020 08:04:09 GMT</pubDate>
            <atom:updated>2020-10-05T08:04:09.967Z</atom:updated>
            <content:encoded><![CDATA[<p>Hello everyone, in this medium post , I would like to describe the importance of CG Kit for HUAWEI ,what it means for human life, technological usage areas and following what to do by using it , how to use it and integration of code side and how to compound Computer Graphics with UNITY for as general information.</p><h4><strong>What is the Computer Graphics?</strong></h4><p><strong>“Computer graphics”</strong> is the branch of computer science that concerning with the visualization of computers. In other words, It is the code for computers to create and modify images on a display device. It consists of software techniques to create, store, modify and represent images.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/591/1*jpQBDdZXmOSeym5qVoFZ4Q.png" /></figure><h4><strong>Why is so computer graphics important?</strong></h4><p>Nowadays, the importance of computer graphics lies in its own applications. There are some features that are indispensable and this helps to quickly visualize them in many areas such as automotive, aerospace etc.</p><p>Before turning up computer graphics, designers have worked on expensive modeling and time-consuming kit making. Now, designers can interactively view and modify models of their shapes using a computer.</p><p>Computer graphics has also expanded the boundaries of art and entertainment. Movies such as Jurassic Park , it’s used for computer graphics to create images that test the bounds of imagination.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*KLcL6AcIAIC4c6F-LZVnKQ.png" /><figcaption>Picture about CG</figcaption></figure><h4>What is the VULKAN API ?</h4><p><strong>“Vulkan” </strong>is a low-overhead, cross-platform <strong>3D graphics and computing API</strong>. Features the Vulkan API with atom level capabilities such as materials,models,light use and post effects.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*wkcQ-IoXSywSrSp59VCeEw.png" /><figcaption><strong>VULKAN IP</strong></figcaption></figure><p><strong>“Vulkan” </strong>do, as well as other <strong>APIs</strong>, to provide its predecessor <strong>OpenGL </strong>several advantages. <strong>Vulkan </strong>underload offers more control over the <strong>GPU </strong>and lower <strong>CPU usage</strong>. In different words, it’s said that fierce competitor against <strong>“DirectX”</strong> itself.</p><h3>CG KIT ARCHITECHTURE</h3><p>The ability of developers to integrate processing capability into projects with minimal workload provides easy-to-use atomic processing capability and <br> Also, provides a versatile rendering framework for 3D native application developers with practical functions such as multi-threaded model loading.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*bcwzrW8LdKc7PfDtJxM2LA.png" /><figcaption><strong>Architecture of CG Kit</strong></figcaption></figure><h4>Advantages of CG Kit</h4><p>Below table tells us , what the capabilities of CG Kit.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qHt9PbFGFMyssnbrMbCOjw.png" /><figcaption><strong>Capabilities of CG Kit</strong></figcaption></figure><h4>Which fields can be used for</h4><p>Computer graphics deals with movement, creation ,data storage of distinct type of objects and images.</p><p>Some of the applications of computer graphics are such as;</p><ul><li>Computer Art,</li><li>Entertainment,</li><li>Visualization,</li><li>Machine Drawing,</li><li>Image Processing,</li><li>Graphical User Interface etc.</li></ul><p>A few example pictures about the CG.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*ogAZWySK8fk6V4qdGN3YXQ.png" /><figcaption><strong>Shadow Effect Rendering</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*9iaBWJUjqW9aLUSVmY5pfw.png" /><figcaption><strong>Game Rendering</strong></figcaption></figure><h3>Getting Started</h3><p>You can reach the CG Kit with below link to its main webpage.</p><p><a href="https://developer.huawei.com/consumer/en/hms/huawei-computer-graphics/"><strong>https://developer.huawei.com/consumer/en/hms/huawei-computer-graphics/</strong></a></p><p>There some requirements that you need to Integration preparations and development process for CG Kit which are ;</p><p><strong>Software Requirements</strong></p><ul><li>Android Studio 3.5 or later,</li><li>SDK Platform 19 or later,</li><li>Smartphone: Android 8.0 or later</li><li>Gradle 4.0.1 or later</li></ul><p><strong>Required Knowledge</strong></p><ul><li>Android basics,</li><li>Android NDK</li><li>Android Native APK</li></ul><h4>Restrictions</h4><p>Every Huawei phone user can used for development the kit ,There is no restriction but should be paid attention <strong>“Vulkan” </strong>version<strong> </strong>and <strong>“Android Version”</strong> .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*V1HWyY2JQrAcdCnf1pr_vw.png" /><figcaption><strong>Supported Devices</strong></figcaption></figure><h3>Steps Before Development</h3><p>Before starting to apps development , some steps should be applied to your own project.</p><p><strong>1-</strong> <strong>Preparations for Integrating HUAWEI HMS Core</strong> section .Just like every kit these are important rules that we have to apply.</p><p>The steps should be known is in the below link;</p><p>You can find the necessary information easily that you need.</p><p><a href="https://developer.huawei.com/consumer/en/codelab/HMSPreparation/index.html#0"><strong>https://developer.huawei.com/consumer/en/codelab/HMSPreparation/index.html#0</strong></a></p><p><strong>2- </strong>After applying <strong>step 1 ,</strong>you are going to have knowledge these ;</p><ul><li>Creating an App in AppGallery Connect</li><li>Creating an Android Studio Project</li><li>Generating a Signing Certificate</li><li>Generating a Signing Certificate Fingerprint</li><li>Adding fingerprint certificate to AppGallery Connect</li><li>Enabling the API Service on the AppGallery Connect</li><li>Add Configuration</li><li>Configure project signature</li><li>Sync Project</li></ul><p><strong>3- </strong>Firstly, the sample code does not include the SDK.So that you have to download The SDK and import it to your own project. Otherwise you can’t execute the project. Of course for doing this <strong>You will need to login with your </strong><a href="https://id1.cloud.huawei.com/AMW/portal/homepage.html"><strong>“HUAWEI Developers”</strong></a><strong> account.</strong></p><p>Here is the SDK link that you need ; <br> <a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001050441521"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001050441521</strong></a></p><p>Secondly, The models, cubes files are not including in the sample source code. Thus, You need to create your own models, cubes files because of legal problems, copyright concerns etc.</p><p><strong>4-</strong> Lastly, I have talked about how to create a android project in the above section named as <strong>“Steps Before Development”.</strong></p><p>While creating project , please pay attention that it’s going to be created as <strong>Native C++ project.</strong></p><p>Make sure that your <strong>build.gradle</strong> file is like this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/689/1*_cHjXw5mxVV6QioKO_3vbQ.png" /><figcaption><strong>build dependencies of CMake in the /app/build.gradle file.</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/601/1*VvBWVQdH3HrI3rYIyPXVZg.png" /><figcaption><strong>NDK ABI filter</strong></figcaption></figure><p>Watch out the minimum <strong>“NDK”</strong> &amp; <strong>“SDK”</strong> version is supported. it can be changed <strong>from HMS Core version to version</strong> ,In this version this is the updated as above.it can be run at least Android version 8.0 or later.</p><h4><strong>Integration the SDK</strong></h4><p>As you remember , I talked to you about how important the SDK.</p><p><strong>After downloading The SDK</strong> ,you will see the picture as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/509/1*tyvTmVfKksozQ5HkM02q3w.png" /></figure><p>After that ,There are<strong> 2 steps</strong> that we are going to do;</p><p><strong>1- </strong>After clicking <strong>“Include”</strong> file you will see some distinct folders as below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/539/1*nHhfiRqMODKQBsT6Nna0CA.png" /></figure><p>You should copy the header files in the SDK to the <strong>“app\src\main\cpp\include\CGRenderingFramework” </strong>directory in Android Studio.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/557/1*9oF9Aqb4jguc7QoBGAAyzQ.png" /></figure><p><strong>2-</strong> Secondly, After opening “<strong>libs” </strong>folder you will see as below picture.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/397/1*fqEPtdZffVpLIrLeJSToEA.png" /><figcaption><strong>Inside of libs folder</strong></figcaption></figure><p>This is the library that you need to import it again in the Android Studio.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/194/1*8pOY-uOjdJtSOD5NavNMQg.png" /><figcaption><strong>.so extension library</strong></figcaption></figure><p>Copy the .so files in the SDK package to the resource library.</p><p>Copy <strong>libs\arm64-v8a\libcgkit.so</strong> &amp; <strong>libs\armeabi-v7a\libcgkit.so</strong> in the SDK package to <strong>libs/arm64-v8a</strong> and <strong>/libs/armeabi-v7a</strong> in Android Studio, respectively.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/463/1*DIICa2bYXSZyaDQG1Ldj4w.png" /></figure><p><strong>3-</strong>After importing necessary components, by clicking on <strong>Refresh Linked C++ Projects</strong> under <strong>Build</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/297/1*9cmOuarLzVt2Y8m0Hc4pBQ.png" /></figure><p><strong>4- </strong>After that open the <strong>MainApplication.cpp</strong> file If the code blogs are not even highlighted in red, Bingo !!! that means the configuration is successful and compile the project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/406/1*ToVaE4xBWqMqkhOdQB1KPg.png" /></figure><p>Lastly ,don’t forget to click <strong>Sync Project with Gradle Files</strong>.</p><h3><strong>Preparing Model Data</strong></h3><p>CG Rendering Framework supports customized models and material files, and the parsing of OBJ models, .png textures, and SPIR-V shaders.</p><p>There are some procedures to have your own <strong>customized materials</strong> which are;</p><ul><li>Create a cubemaps</li><li>Six square textures</li><li>Vertex shader (the global constant data structure with <strong>set</strong> and <strong>binding</strong> settings)</li><li>Pixel shader (the light data structure with <strong>set</strong> and <strong>binding</strong> settings)</li><li>The texture channels</li></ul><p>You can access all the details from the link below.</p><p><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/demo-data-process-0000001050200023"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/demo-data-process-0000001050200023</strong></a></p><h3><strong><em>Application Development Process</em></strong></h3><h4><strong>Process Overview</strong></h4><p>For application development, Actually as developer you need to some <strong>loading resources</strong> which has provide to create the environment for preparing the your own world which are ;</p><ul><li>Making your own SkyBox</li><li>Generating Camera Instance</li><li>Compose a Scene object and model</li><li>Creating a light object</li><li>Configuring Gesture Events</li></ul><h3>Permission of Functions and Codifying</h3><p><strong>1.</strong> You need to have write and read permission is implicitly granted this permission. Lets get added the permission on Manifest file.</p><p><strong>WRITE_EXTERNAL_STORAGE</strong> allows an application to write to external storage.</p><p><strong>READ_EXTERNAL_STORAGE </strong>allows an application to read from external storage.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/03f17cb4dad68be46197d3f38049e874/href">https://medium.com/media/03f17cb4dad68be46197d3f38049e874/href</a></iframe><p><strong>2.</strong> Configure the Maven repository address in the project-level <strong>build.gradle</strong> file.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/386f24e04ad5effe1ce978e51ddbfe65/href">https://medium.com/media/386f24e04ad5effe1ce978e51ddbfe65/href</a></iframe><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4e652508e40146023339d5a39539a650/href">https://medium.com/media/4e652508e40146023339d5a39539a650/href</a></iframe><p><strong>3.</strong> Configure the CG SDK as a dependency in the app-level <strong>build.gradle</strong> file.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/58ecde3f902391a5b6ee99bad665b7ec/href">https://medium.com/media/58ecde3f902391a5b6ee99bad665b7ec/href</a></iframe><p><strong>4.</strong> All you need is Create and run an instance object.<br>Instantiate <strong>MainApplication</strong>, which inherits the <strong>BaseApplication </strong>object. Start the main rendering loop <strong>MainLoop()</strong>.<br>Sample code is below :</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d67e995474a261654c4691c87681b9d2/href">https://medium.com/media/d67e995474a261654c4691c87681b9d2/href</a></iframe><p><strong>5.</strong> Functions are implemented in <strong>MainApplication.cpp</strong>.<br> You need to instantiate an “<strong>cameraObj” </strong>object in the camera scene, obtain the Camera object <strong>mainCamera</strong>, <br>set <strong>mainCamera</strong> parameters (including the projection angle and type, target position, and view point position)etc.<br>Sample code is below:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9dded7f2db23982553c13302b5e843e5/href">https://medium.com/media/9dded7f2db23982553c13302b5e843e5/href</a></iframe><p><strong>6.</strong> Create a <strong>“Scene object”</strong> and loads <strong>the model, texture, and more</strong>.<br>Sample code is below :</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0f3e8e3757ba323c5de74dcf9f3a3eb7/href">https://medium.com/media/0f3e8e3757ba323c5de74dcf9f3a3eb7/href</a></iframe><p><strong>7. </strong>Create a <strong>skybox</strong> , it’s important for your all resources, All of items are created on it.<br>Sample code is below:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/13fc879c3838783c5a3c53667c0a7775/href">https://medium.com/media/13fc879c3838783c5a3c53667c0a7775/href</a></iframe><p><strong>8.</strong> Create<strong> “light resources”. </strong>So that A light class will be used for placing and acquiring the light’s color, type, position etc.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0781d20b97417b6deb8ece0f0203f6e1/href">https://medium.com/media/0781d20b97417b6deb8ece0f0203f6e1/href</a></iframe><p><strong>9. </strong>Configure <strong>“gesture events”</strong>.</p><p>A touch event class is used for monitoring single-touch or multi-touch actions. Some of them are such as <a href="https://developer.huawei.com/consumer/en/doc/HMSCore-References-V5/touchaction-0000001050268360-V5#EN-US_TOPIC_0000001050268360__section42835255313"><strong>TOUCH_ACTION_DOWN</strong></a><strong> ,</strong><a href="https://developer.huawei.com/consumer/en/doc/HMSCore-References-V5/touchaction-0000001050268360-V5#EN-US_TOPIC_0000001050268360__section42835255313"><strong>TOUCH_ACTION_UP</strong></a><strong> </strong>and <strong>more</strong>.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/572d474a30784e66d44a25c026155269/href">https://medium.com/media/572d474a30784e66d44a25c026155269/href</a></iframe><h3>Creating “Loading Resources” by using Unity</h3><p>Especially <strong>Cubemaps </strong>and <strong>models </strong>file are so important and without them you can’t continue to occour your own design. Therefore I would like to share with you UNITY where can be create your all models as you wish.</p><p>Unity has the equipment to help you in this regard and meet all your needs.</p><h4><strong>Making Skybox</strong></h4><p>Firstly , Huawei has no its own <strong>skyboxes </strong>sample yet , Thus you need to prepare your own skyboxes until as they are released within sample source code.<br>The following website provides you how to make your own skyboxes and gives more information by using Unity;</p><p><a href="https://docs.unity3d.com/Manual/skyboxes-using.html"><strong>https://docs.unity3d.com/Manual/skyboxes-using.html</strong></a></p><p><a href="https://docs.unity3d.com/560/Documentation/Manual/HOWTO-UseSkybox.html"><strong>https://docs.unity3d.com/560/Documentation/Manual/HOWTO-UseSkybox.html</strong></a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*i9EUaBjH560hMJo5nAjScA.png" /><figcaption><strong>Sample of Creating Skybox</strong></figcaption></figure><h4><strong>Scene Objects and Models</strong></h4><p>You can find how to important and how to use it in the project using unity ,the scene objects and models in detail below link.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/851/1*zJYinL-gNyjqhO4nRGJIkA.png" /><figcaption>Sample of Scene objects</figcaption></figure><p><a href="https://docs.unity3d.com/Manual/CreatingScenes.html"><strong>https://docs.unity3d.com/Manual/CreatingScenes.html</strong></a></p><p><a href="https://docs.unity3d.com/560/Documentation/Manual/UNetSceneObjects.html">Scene Objects</a></p><h4><strong>Generating a Camera Instance</strong></h4><p>Camera Effects are a very important ,especially for the game’s look and feelings. Things like color correction, bloom, and film grain can add a nice polish to your game. Unity has built-in scripts for camera effects. In this section, it shows us how to add camera effects to your main camera in a Unity scene. I put here some links and be sure that when you read this , you will have nice knowledge in your mind with this specifications.</p><p><a href="https://docs.unity3d.com/ScriptReference/Camera-main.html"><strong>https://docs.unity3d.com/ScriptReference/Camera-main.html</strong></a></p><p><a href="https://docs.unity3d.com/ScriptReference/Camera.html"><strong>https://docs.unity3d.com/ScriptReference/Camera.html</strong></a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/752/1*_DKYB4Hak04Ls9vr_Kkz5Q.gif" /><figcaption>Sample of Camera Instance</figcaption></figure><p>When you watch the below link video, you will have basic information about how to use camera game object by using unity.</p><p><a href="https://www.youtube.com/watch?v=BEeHvKO7Fdk"><strong>https://www.youtube.com/watch?v=BEeHvKO7Fdk</strong></a></p><h4><strong>Creating a Light Object</strong></h4><p>Here is talked about how lighting works with <strong>Unity’s real-time Global Illumination engine.</strong></p><p>Some lighting techniques will be explained, and how to set it up your project them with using unity.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*yVgInRYXv91wzcMfPBObHA.gif" /><figcaption><strong>Sample of Lighting and Rendering</strong></figcaption></figure><p>In Below links, you will find introduction to lighting and rendering and lighting technique ,type of lights and more .</p><p><a href="https://learn.unity.com/tutorial/introduction-to-lighting-and-rendering#5c7f8528edbc2a002053b529"><strong>https://learn.unity.com/tutorial/introduction-to-lighting-and-rendering#5c7f8528edbc2a002053b529</strong></a></p><p><a href="https://docs.unity3d.com/ScriptReference/Light.html"><strong>https://docs.unity3d.com/ScriptReference/Light.html</strong></a></p><p><a href="https://docs.unity3d.com/Manual/Lighting.html"><strong>https://docs.unity3d.com/Manual/Lighting.html</strong></a></p><h4>Thank you for your time and understanding. I will hope to see you in my next medium article GoodBye…</h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d1474112c1f9" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers/implementation-of-huawei-computer-graphics-kit-and-introduction-on-unity-d1474112c1f9">Implementation of HUAWEI Computer Graphics Kit and Introduction on Unity</a> was originally published in <a href="https://medium.com/huawei-developers">Huawei Developers</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HUAWEI Bilgisayar Grafikleri Kitinin Uygulanması ve Unity’ye Giriş]]></title>
            <link>https://medium.com/huawei-developers-tr/huawei-bilgisayar-grafikleri-kitinin-uygulanmas%C4%B1-ve-unityye-giri%C5%9F-9f86e8c4e0e3?source=rss-22aec095ced2------2</link>
            <guid isPermaLink="false">https://medium.com/p/9f86e8c4e0e3</guid>
            <category><![CDATA[vulkan]]></category>
            <category><![CDATA[computer-graphics]]></category>
            <category><![CDATA[huawei-mobile-service]]></category>
            <category><![CDATA[unity3d]]></category>
            <category><![CDATA[hms]]></category>
            <dc:creator><![CDATA[Cenk Türker]]></dc:creator>
            <pubDate>Mon, 05 Oct 2020 07:24:29 GMT</pubDate>
            <atom:updated>2020-10-05T07:24:29.552Z</atom:updated>
            <content:encoded><![CDATA[<p>Herkese merhaba ,Bu medium yazısında, CG Kit’in HUAWEI için önemini, insan yaşamı için ne anlama geldiğini, teknolojik kullanım alanlarını ve onu kullanarak ne yapılacağını, nasıl kullanılacağını ve kod tarafının entegrasyonunu ve genel bilgi olarak ise,UNITY ile beraber nasıl uygulanabilirliğini anlatacağım.</p><h4><strong>Bilgisayar Grafikleri nedir?</strong></h4><p><strong>“Bilgisayar grafikleri”</strong>, bilgisayarların görselleştirilmesiyle ilgili bilgisayar biliminin dalıdır. Başka bir deyişle, bilgisayarların bir görüntüleme cihazında görüntüleri oluşturması ve değiştirmesi için kod parçacıklarıdır. Görüntüleri oluşturmak, saklamak, değiştirmek ve temsil etmek için yazılım tekniklerinden oluşmaktadır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/591/1*jpQBDdZXmOSeym5qVoFZ4Q.png" /><figcaption><strong>Bilgisayar Grafikleri Resim-1</strong></figcaption></figure><h4><strong>Bilgisayar grafikleri neden bu kadar önemli ?</strong></h4><p>Günümüzde bilgisayar grafiklerinin önemi kendi uygulamalarında yatmaktadır. Vazgeçilmez olan bazı özellikler vardır ve bu, otomotiv, havacılık vb. Birçok alanda bunların hızlı bir şekilde görselleştirilmesine yardımcı olur.</p><p>Bilgisayar grafiklerini ortaya çıkmadan önce, tasarımcılar pahalı modelleme ve zaman alan kit yapımı üzerinde çalışıyorlardı. Artık tasarımcılar, bir bilgisayar kullanarak şekillerinin modellerini etkileşimli olarak görüntüleyebilir ve değiştirebilir.</p><p>Bilgisayar grafikleri, sanat ve eğlencenin sınırlarını da genişletmiştir. Jurassic Park gibi filmler, bilgisayar grafiklerinde hayal gücünün sınırlarını test eden görüntüler oluşturmak için kullanılmaktadır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*KLcL6AcIAIC4c6F-LZVnKQ.png" /><figcaption><strong>Bilgisayar Grafikleri Resim-2</strong></figcaption></figure><h4><strong>VULKAN API nedir ?</strong></h4><p><strong>“Vulkan”</strong> düşük maliyetli, çapraz platformlu bir 3D grafik ve bilgi işlem API’sidir. Malzemeler, modeller, ışık kullanımı ve post efektleri gibi atom seviyesinde yeteneklere sahip Vulkan API’ye sahiptir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*wkcQ-IoXSywSrSp59VCeEw.png" /><figcaption><strong>VULKAN IP</strong></figcaption></figure><p>“Vulkan”, önceki OpenGL’ye göre çeşitli avantajlar sağlamak için diğer API’lerin önüne geçebiliyor. Vulkan belirli bir kapasite altında olan üretimi ile, GPU üzerinde daha fazla kontrol ve daha düşük CPU kullanımı sunmaktadır. Farklı bir deyişle, “DirectX” in kendisine karşı çetin bir rakip olduğu söylenmektedir.</p><h3>CG KIT MİMARİSİ</h3><p>Geliştiricilerin minimum iş yükü ile işleme kabiliyetini projelere entegre etme yeteneği, kullanımı kolay atomik işleme yeteneği sağlamakla beraber,<br> çok iş parçacıklı model yükleme gibi pratik işlevlere sahip 3 boyutlu yerel uygulama geliştiricileri için çok yönlü bir işleme çerçevesi sağlar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*bcwzrW8LdKc7PfDtJxM2LA.png" /><figcaption><strong>Architecture of CG Kit</strong></figcaption></figure><h4><strong>Computer Graphics Kitinin Avantajları</strong></h4><p>CG Kit’in neler yapabildiğini anlatan tablo yer almaktadır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qHt9PbFGFMyssnbrMbCOjw.png" /><figcaption><strong>CG Kit’in yetenekleri</strong></figcaption></figure><h4><strong>Hangi alanlar için kullanılabilir ?</strong></h4><p>Bilgisayar grafikleri, farklı türdeki nesnelerin ve görüntülerin hareketi, oluşturulması, veri depolanması ile ilgilidir.</p><p>Bilgisayar grafiği uygulamalarından bazıları;</p><ul><li>Bilgisayar Sanatı,</li><li>Eğlence,</li><li>Görselleştirme,</li><li>Makine Çizimi,</li><li>Görüntü işleme,</li><li>Grafik Kullanıcı Arayüzü vb.</li></ul><p>CG hakkında birkaç örnek resim.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*ogAZWySK8fk6V4qdGN3YXQ.png" /><figcaption><strong>Gölge Efekti Oluşturma</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*9iaBWJUjqW9aLUSVmY5pfw.png" /><figcaption>Oyun oluşturma</figcaption></figure><h3>Başlangıç</h3><p>CG Kitine ana web sayfasına aşağıdaki bağlantıdan ulaşabilirsiniz.</p><p><a href="https://developer.huawei.com/consumer/en/hms/huawei-computer-graphics/">Computer Graphics Kit - HMS Core - HUAWEI Developer</a></p><p>CG Kit için entegrasyon hazırlıkları ve geliştirme süreci için ihtiyaç duyacağınız bazı gereksinimler şunlardır:</p><p><strong>Yazılım Gereksinimleri</strong></p><ul><li>Android Studio 3.5 yada sonrası,</li><li>SDK Platform 19 yada sonrası,</li><li>Smartphone: Android 8.0 yada sonrası</li><li>Gradle 4.0.1 yada sonrası</li></ul><p><strong>Gerekli Bilgiler</strong></p><ul><li>Android temelleri,</li><li>Android NDK</li><li>Android Yerli APK</li></ul><h4>Kısıtlamalar</h4><p>Her Huawei telefon kullanıcısı kiti geliştirmek için kullanabilir, herhangi bir kısıtlama yoktur ancak <strong>“Vulkan”</strong> versiyonu ve <strong>“Android Versiyonu”</strong> dikkate alınmalıdır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*V1HWyY2JQrAcdCnf1pr_vw.png" /><figcaption><strong>Desteklenen Cihazlar</strong></figcaption></figure><h3>Geliştirme Öncesi Adımlar</h3><p>Uygulama geliştirmeye başlamadan önce, kendi projenize bazı adımları izlemeniz gerekmektedir.</p><p>1- “<strong>Preparations for Integrating HUAWEI HMS Core”</strong> Tıpkı her kit gibi bunlar da uygulamamız gereken önemli kurallardır.</p><p>Bilinmesi gereken adımlar aşağıdaki bağlantıdadır;</p><p>İhtiyaç duyduğunuz gerekli bilgileri kolayca bulabilirsiniz.</p><p><a href="https://developer.huawei.com/consumer/en/codelab/HMSPreparation/index.html#0">Preparations for Integrating HUAWEI HMS Core(Android)</a></p><p><strong>2- 1. adımı</strong> uyguladıktan sonra, bunları öğreneceksiniz;</p><ul><li>AppGallery Connect’te Uygulama Oluşturma</li><li>Android Studio Projesi Oluşturma</li><li>İmza Sertifikası Oluşturma</li><li>İmzalama Sertifikası Dijital Parmak İzi Oluşturma</li><li>AppGallery Connect’e parmak izi sertifikası ekleme</li><li>AppGallery Connect’te API Hizmetini Etkinleştirme</li><li>Yapılandırma Ekleme</li><li>Proje imzasını yapılandırma</li><li>Proje senkronizasyonu</li></ul><p><strong>3- </strong>İlk olarak, örnek kod SDK ‘yı içermemektedir.Böylece SDK’yı indirmeniz ve kendi projenize aktarmanız gerekir.Aksi takdirde projeyi yürütemezsiniz. Elbette bunu yapmak için <a href="https://id1.cloud.huawei.com/AMW/portal/homepage.html"><strong>“HUAWEI Developer”</strong></a> hesabınızla oturum açmanız gerekecek.</p><p>İşte ihtiyacınız olan SDK bağlantısı;</p><p><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001050441521"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Library/sdk-download-0000001050441521</strong></a></p><p>İkinci olarak, modeller, küp dosyaları örnek kaynak koduna dahil değildir. Bu nedenle, yasal sorunlar, telif hakkı endişeleri vb. Nedeniyle kendi modellerinizi, küp dosyalarınızı oluşturmanız gerekiyor.</p><p><strong>4-</strong> Son olarak yukarıdaki <strong>“Geliştirme Öncesi Adımlar” </strong>adlı bölümde bir android projesinin nasıl oluşturulacağından bahsetmiştim.</p><p>Proje oluştururken <strong>Native C ++</strong> <strong>projesi </strong>olarak oluşturulacağına lütfen dikkat ediniz.</p><p><strong>Build.gradle</strong> dosyanızın böyle olduğundan emin olun.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/689/1*_cHjXw5mxVV6QioKO_3vbQ.png" /><figcaption><strong>build dependencies of CMake in the /app/build.gradle file.</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/601/1*VvBWVQdH3HrI3rYIyPXVZg.png" /><figcaption><strong>NDK ABI filter</strong></figcaption></figure><p>Minimum <strong>“NDK”</strong> ve <strong>“SDK” </strong>sürümünün desteklendiğine dikkat edin. HMS Core versiyonundan versiyona değiştirilebilir, bu versiyonda yukarıdaki gibi güncellenmiştir. en az Android versiyon 8.0 veya üzeri çalıştırılabilir.</p><h4><strong>SDK’nın entegrasyonu</strong></h4><p>Hsadatırlarsanız, SDK’nın ne kadar önemli olduğu hakkında sizinle konuşmuştuk.<br><strong>SDK’yı </strong>indirdikten sonra aşağıdaki resmi göreceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*tyvTmVfKksozQ5HkM02q3w.png" /></figure><p>Bundan sonra yapacağımız 2 adım var;</p><p>1- <strong>“Include”</strong> dosyasını tıkladıktan sonra aşağıdaki gibi bazı farklı klasörler göreceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*nHhfiRqMODKQBsT6Nna0CA.png" /></figure><p>SDK’daki başlık dosyalarını, Android Studio’daki <strong>“app \ src \ main \ cpp \ include \ CGRenderingFramework” </strong>dizinine kopyalamanız gerekir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/557/1*9oF9Aqb4jguc7QoBGAAyzQ.png" /></figure><p>2- İkinci olarak, <strong>“libs”</strong> klasörünü açtıktan sonra aşağıdaki resimdeki gibi göreceksiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/397/1*fqEPtdZffVpLIrLeJSToEA.png" /><figcaption><strong>Libs klasör içi</strong></figcaption></figure><p>Bu, Android Studio’da tekrar içe aktarmanız gereken kitaplıktır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/194/1*8pOY-uOjdJtSOD5NavNMQg.png" /><figcaption><strong>.so uzantılı kütüphane</strong></figcaption></figure><p>SDK paketi içinde yer alan<strong>libs \ arm64-v8a \ libcgkit.so &amp; libs \ armeabi-v7a \ libcgkit.so</strong> dosyalarını sırasıyla Android Studio’da <strong>libs / arm64-v8a</strong> ve<strong> / libs / armeabi-v7a’ya</strong> kopyalayın.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/463/1*DIICa2bYXSZyaDQG1Ldj4w.png" /></figure><p>3-Gerekli bileşenleri içe aktardıktan sonra, Build altındaki Bağlantılı<strong> C ++ Projelerini </strong>Yenile’ye tıklayınız.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/297/1*9cmOuarLzVt2Y8m0Hc4pBQ.png" /></figure><p>4- Bundan sonra <strong>MainApplication.cpp </strong>dosyasını açın Kod blogları kırmızıyla vurgulanmamışsa, Bingo !!! bu, konfigürasyonun başarılı olduğu ve projeyi derlediği anlamına gelir.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/406/1*ToVaE4xBWqMqkhOdQB1KPg.png" /></figure><p>Son olarak, projeyi GradleFiles ile senkronizasyonu yapmayı unutmayın.</p><h3>Model Verilerinin Hazırlanması</h3><p>CG Rendering Framework, özelleştirilmiş modelleri ve malzeme dosyalarını ve OBJ modellerinin, .png dokularının ve SPIR-V gölgelendiricilerinin ayrıştırılmasını destekler.</p><p>Kendi özel malzemelerinize sahip olmak için bazı prosedürler vardır:</p><ul><li>Küp haritalar oluşturma</li><li>Altı kare dokusu</li><li>Köşe gölgelendiricisi (set ve bağlama ayarlarına sahip global sabit veri yapısı)</li><li>Piksel gölgelendirici (set ve ciltleme ayarlarına sahip hafif veri yapısı)</li><li>Doku kanalları</li></ul><p>Tüm detaylara aşağıdaki bağlantıdan ulaşabilirsiniz.</p><p><a href="https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/demo-data-process-0000001050200023"><strong>https://developer.huawei.com/consumer/en/doc/development/HMSCore-Guides/demo-data-process-0000001050200023</strong></a></p><h3>Uygulama Geliştirme Süreci</h3><p><strong>Sürece Genel Bakış</strong></p><p>Uygulama geliştirme için, Aslında geliştirici olarak kendi dünyanızı hazırlamak için ortam yaratmayı sağlayan bazı <strong>“Loading Resources”</strong> ihtiyacınız var.</p><ul><li>Kendi SkyBox’ınızı yapmak</li><li>Kamera Örneği Oluşturma</li><li>Bir Scene nesnesi ve modeli oluşturun</li><li>Işık objesi yaratmak</li><li>Hareket Olaylarını Yapılandırma</li></ul><h3>İşlev İzni ve Kodlama</h3><p>1. <strong>Yazma </strong>ve <strong>okuma </strong>izninizin olması gerekir, bu izin dolaylı olarak verilir. Manifest dosyasına izin ekleyelim.</p><p><strong>“WRITE_EXTERNAL_STORAGE” </strong>, bir uygulamanın harici depolamaya yazmasına izin verir.</p><p><strong>READ_EXTERNAL_STORAGE</strong> , bir uygulamanın harici depolamadan okumasına izin verir.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/03f17cb4dad68be46197d3f38049e874/href">https://medium.com/media/03f17cb4dad68be46197d3f38049e874/href</a></iframe><p>2. Proje düzeyindeki <strong>build.gradle</strong> dosyasında <strong>“Maven repository”</strong> adresini yapılandırın.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/386f24e04ad5effe1ce978e51ddbfe65/href">https://medium.com/media/386f24e04ad5effe1ce978e51ddbfe65/href</a></iframe><p><strong>3.</strong> CG SDK’yı uygulama düzeyindeki <strong>build.gradle </strong>dosyasında yapılandıralım.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/58ecde3f902391a5b6ee99bad665b7ec/href">https://medium.com/media/58ecde3f902391a5b6ee99bad665b7ec/href</a></iframe><p><strong>4.</strong> İhtiyacınız olan tek şey bir örnek nesnesi oluşturmak ve çalıştırmaktır.<br><strong>BaseApplication </strong>nesnesinden türeyen“<strong>MainApplication” </strong>örneğini oluşturun. Ana işleme döngüsü <strong>MainLoop ()</strong> ‘u başlatın.<br>Örnek kod aşağıdadır:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d67e995474a261654c4691c87681b9d2/href">https://medium.com/media/d67e995474a261654c4691c87681b9d2/href</a></iframe><p><strong>5.</strong> Fonksiyonlar “<strong>MainApplication.cpp”</strong>de uygulanır.<br>Kamera sahnesinde bir <strong>“cameraObj” </strong>nesnesini başlatmanız, Camera nesnesi <strong>mainCamera</strong>’yı almanız gerekir,<br>mainCamera parametrelerini ayarlayın (yansıtma açısı ve türü, hedef konumu ve görüş noktası konumu dahil) vb.<br>Örnek kod aşağıdadır:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9dded7f2db23982553c13302b5e843e5/href">https://medium.com/media/9dded7f2db23982553c13302b5e843e5/href</a></iframe><p><strong>6.</strong> Bir <strong>“Scene object”</strong> oluşturun ve<strong> modeli, dokuyu ve daha fazlasını</strong> yükleyin.<br>Örnek kod aşağıdadır:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0f3e8e3757ba323c5de74dcf9f3a3eb7/href">https://medium.com/media/0f3e8e3757ba323c5de74dcf9f3a3eb7/href</a></iframe><p><strong>7. </strong>Bir “S<strong>kybox”</strong> oluşturun, tüm kaynaklarınız için önemlidir, tüm öğeler onun üzerinde yaratılmaktadır.<br>Örnek kod aşağıdadır.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/13fc879c3838783c5a3c53667c0a7775/href">https://medium.com/media/13fc879c3838783c5a3c53667c0a7775/href</a></iframe><p><strong>8. “Light Resources” </strong>oluşturun. Böylece ışığın rengini, türünü, konumunu vb. Yerleştirmek ve elde etmek için bir ışık sınıfı kullanılacaktır.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/0781d20b97417b6deb8ece0f0203f6e1/href">https://medium.com/media/0781d20b97417b6deb8ece0f0203f6e1/href</a></iframe><p><strong>9.</strong> <strong>“Gesture Events”</strong> yapılandırın.<br>Tek dokunuşlu veya çoklu dokunma eylemlerini izlemek için bir dokunma olayı sınıfı kullanılır. Bunlardan bazıları <strong>TOUCH_ACTION_DOWN</strong>, <strong>TOUCH_ACTION_UP </strong>ve daha fazlasıdır.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/572d474a30784e66d44a25c026155269/href">https://medium.com/media/572d474a30784e66d44a25c026155269/href</a></iframe><h3><strong>Unity kullanarak “Loading Resources” Oluşturma</strong></h3><p>Özellikle <strong>“Cubemaps”</strong> ve <strong>”modeller”</strong> dosyası çok önemlidir ve onlarsız kendi tasarımınızı gerçekleştirmeye devam edemezsiniz. Bu nedenle tüm modellerinizi dilediğiniz gibi oluşturabileceğiniz <strong>UNITY</strong>’yi sizlerle paylaşmak istiyorum.</p><p>Unity, bu konuda size yardımcı olacak ve tüm ihtiyaçlarınızı karşılayacak donanıma sahiptir.</p><h4>Skybox Yapımı</h4><p>İlk olarak, Huawei’nin henüz kendi <strong>“SkyBox”</strong> örneği yok, Bu nedenle, örnek kaynak kodunda piyasaya sürülene kadar kendi gökyüzü kutularınızı hazırlamanız gerekir.<br>Aşağıdaki web sitesi size kendi skybox’larınızı Unity kullanarak nasıl yapacağınızı sağlar ve daha fazla bilgi verir;</p><p><a href="https://docs.unity3d.com/Manual/skyboxes-using.html"><strong>https://docs.unity3d.com/Manual/skyboxes-using.html</strong></a></p><p><a href="https://docs.unity3d.com/560/Documentation/Manual/HOWTO-UseSkybox.html">How do I Make a Skybox?</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*i9EUaBjH560hMJo5nAjScA.png" /><figcaption><strong>SkyBox oluşturma</strong></figcaption></figure><h4>Sahne Nesneleri ve Modelleri</h4><p>Unity, sahne objeleri ve modellerini kullanarak projede ne kadar önemli ve nasıl kullanılacağını detaylı olarak aşağıdaki linkten öğrenebilirsiniz.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/851/1*zJYinL-gNyjqhO4nRGJIkA.png" /><figcaption>Sample of Scene objects</figcaption></figure><p><a href="https://docs.unity3d.com/Manual/CreatingScenes.html"><strong>https://docs.unity3d.com/Manual/CreatingScenes.html</strong></a></p><p><a href="https://docs.unity3d.com/560/Documentation/Manual/UNetSceneObjects.html">Scene Objects</a></p><h4>Kamera Örneği Oluşturma</h4><p>Kamera Efektleri, özellikle oyunun görünümü ve duyguları için çok önemlidir. Renk düzeltme, çiçeklenme ve film grenleri gibi şeyler oyununuza güzel bir parlaklık katabilir. Unity, kamera efektleri için yerleşik komut dosyalarına sahiptir.</p><p>Bu bölümde, bir Unity sahnesinde ana kameranıza kamera efektlerini nasıl ekleyeceğinizi gösterir. Buraya bazı linkler bırakıyorum ve emin olun ki bunu okuduğunuzda zihninizde güzel bilgiler yer edinecektir.</p><p><a href="https://docs.unity3d.com/ScriptReference/Camera-main.html"><strong>https://docs.unity3d.com/ScriptReference/Camera-main.html</strong></a></p><p><a href="https://docs.unity3d.com/ScriptReference/Camera.html"><strong>https://docs.unity3d.com/ScriptReference/Camera.html</strong></a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/752/1*_DKYB4Hak04Ls9vr_Kkz5Q.gif" /><figcaption>Kamera Örneği</figcaption></figure><p>Aşağıdaki link videosunu izlediğinizde, kamera oyun nesnesinin nasıl kullanılacağı hakkında temel bilgilere sahip olacaksınız.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FBEeHvKO7Fdk%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DBEeHvKO7Fdk&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FBEeHvKO7Fdk%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/50ae8e2d73b08eb751c758652851b1c3/href">https://medium.com/media/50ae8e2d73b08eb751c758652851b1c3/href</a></iframe><h4>Işık Nesnesi Oluşturma</h4><p><strong>“Unity’nin gerçek zamanlı Global Illumination” </strong>motoruyla aydınlatmanın nasıl çalıştığı hakkında bahsediliyor.</p><p>Bazı aydınlatma teknikleri ve projeniz içerisinde nasıl kuracağınız anlatan bir kısım yer almaktadır.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*yVgInRYXv91wzcMfPBObHA.gif" /><figcaption><strong>Sample of Lighting and Rendering</strong></figcaption></figure><p>Aşağıdaki bağlantılarda işleme ve aydınlatma tekniğine, ışık türlerine ve daha fazlasına giriş bulacaksınız.</p><p><a href="https://learn.unity.com/tutorial/introduction-to-lighting-and-rendering#5c7f8528edbc2a002053b529"><strong>https://learn.unity.com/tutorial/introduction-to-lighting-and-rendering#5c7f8528edbc2a002053b529</strong></a></p><p><a href="https://docs.unity3d.com/ScriptReference/Light.html"><strong>https://docs.unity3d.com/ScriptReference/Light.html</strong></a></p><p><a href="https://docs.unity3d.com/Manual/Lighting.html"><strong>https://docs.unity3d.com/Manual/Lighting.html</strong></a></p><h4><strong>Zaman ayırdığınız ve anlayışınız için teşekkür ederim. Bir sonraki medyum makalemde görüşmek dileğiyle hoşçakalın…</strong></h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9f86e8c4e0e3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/huawei-developers-tr/huawei-bilgisayar-grafikleri-kitinin-uygulanmas%C4%B1-ve-unityye-giri%C5%9F-9f86e8c4e0e3">HUAWEI Bilgisayar Grafikleri Kitinin Uygulanması ve Unity’ye Giriş</a> was originally published in <a href="https://medium.com/huawei-developers-tr">Huawei Developers - Türkiye</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>