To facilitate developers to develop key functions or scenarios, this page summarizes the current sample resources, as shown in the following table:
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates the implementation of the multiton, singleton, and specified ability launch modes in the stage model. | Phone | |
This sample demonstrates the ability management capabilities of the stage model based on Ability Kit. | Phone | |
This sample shows how to develop an app with multiple HAPs. The app in this sample has an entry HAP and two feature HAPs, which provide audio and video playback components. The entry module also uses the audio and video playback components. There are three HAPs for three modules and a main entry HAP to be installed on the device. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by the @ohos.data.preferences module to persistent preferences data. | Phone | |
This sample shows how to perform operations on a relational database (RDB) store, including adding, deleting, modifying, and querying data and performing database transactions. | Phone | |
This sample shows how to accelerate app cold start by caching home page data. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows the basic functions of each sub-module of the language base class library. | Phone | |
In this sample, the ArkTS programming language is used to develop the N-body simulation program for the industry programming language benchmark test item Benchmarks Game to implement orbit calculation for Jupiter-like bodies. | Phone | |
This sample uses the @ohos.taskpool and @ohos.worker APIs to show how to start the worker and taskpool threads. | Phone | |
This sample demonstrates the following use cases of sendable data: multi-thread collaboration (log and dotting) in producer-consumer pattern, and cross-thread communication and UI status update implemented through sendable objects. | Phone | |
This sample shows how to pass and call complex data types, including uint8Array, object, hashMap, pixelMap, and class, between ArkTS and C++. | Phone |
Name | Overview | Device Type |
|---|---|---|
Leveraging the best practices of layered architecture and modular design, along with HarmonyOS's distinctive capability of one-time development for multi-device deployment, this sample showcases an app that embodies the latest technical features of HarmonyOS, empowering developers in the HarmonyOS ecosystem. | Phone | |
This sample uses page-level and app-level state variables to manage app status. | Phone | |
This sample shows the ArkUI component collection, which includes the component, universal, animation, and global method modules. | Phone | |
This sample demonstrates the basic features of the Video component, including video componentization, full-screen display, window display, and video rotation. | Phone | |
This sample shows a typical page for setting an application. The page has different display effects in the small window and large window, reflecting the capability of one-time development for multi-device deployment. | Phone | |
This sample shows the responsive change effect of the multi-column control in various scenarios. | Phone | |
This sample shows the style of the navigation component in different device forms. | Phone | |
This sample describes how to implement a simple clock app with the @ohos.display API and Canvas component. | Phone | |
This sample shows how to use the component to implement password setting, verification, and resetting. | Phone | |
This sample shows how to implement a list that responds to both horizontal and vertical scrolling through nested component scrolling. | Phone | |
This sample implements a news page based on the adaptive layout and responsive layout, allowing the same set of codebase to fit into device of different sizes, such as mobile phones, foldable devices, and tablets. | Phone | |
This sample shows how to implement a custom keyboard application that allows securities codes such as 300 and 600 to be entered with a single tap. | Phone | |
This sample uses an independent router module and dynamic loading method to resolve the issue of routing dependency coupling between multiple HARs/HSPs under a Navigation component. | Phone | |
This sample uses the scrollToIndex method of the List component to implement nested sliding of multiple List components. | Phone | |
This sample showcases an article detail display case where a Web component is nested within a Scroll component and the nestedScroll attribute is used to intercept the scrolling action. | Phone | |
In this sample, the nestedScroll attribute is used to implement the function of sliding up the Scroll container to the Tabs subcomponent. The Tabs subcomponent is mounted to the top, and the content in the List subcomponent can continue to slide. | Phone | |
This sample uses the List component to implement the list editing effects in scenarios such as to-do list management, file management, and notepad. | Phone | |
This sample describes how to use the tab component to add or delete a tab and mainly applies to scenarios such as browsers. | Phone | |
This sample provides common tab navigation UI styles, including bottom navigation, top navigation, and side navigation. | Phone | |
This sample uses CustomDialog, bindContentCover, and bindSheet to implement multiple custom dialog pop-ups. | Phone | |
This sample describes how to use component stacking to build multi-layer stack visual effects. You can use the onScrollFrameBegin event callback function of the Scroll component to accurately capture the scrolling action. During scrolling, attributes such as transparency and height of the component are adjusted in real time, to implement nested scrolling effects, dynamic changing of transparency, and smooth component switching. | Phone | |
This sample describes how to implement the waterfall layout based on the WaterFlow container. Sections are used to implement hybrid layout, and functions such as tab ceiling, pull-down refresh, and unlimited loading are also implemented in this sample. | Phone | |
This sample shows how to use the grid layout and List component to achieve responsive layouts of content for travel accommodation apps on different devices, such as smartphones, foldable screens, and tablets. | Phone | |
This sample guides news page developers in building a news home page from scratch, including common functions such as address selection, dynamic icons and smooth animations for switching between tabs and tab content, pull-down refresh and pull-up loading, and feed stream on the home page. | Phone | |
This sample provides system route verification. The system route table redirects to the page of a module (HSP/HAR), without the need to configure the dependency between different modules to jump. When a page is redirected, the page not redirected and loaded page will not be loaded. This resolves the dependency and coupling issues across different modules and the excessive loading time of the home page. | Phone | |
This sample describes how to implement multiple text effects based on the Text component and common attributes. | Phone | |
This sample describes how to use the enableDataDetector attribute of the Text component to recognize special characters. | Phone | |
This sample demonstrates video playback, manual and automatic invocation of Picture-in-Picture (PiP), and video play and pause control in the PiP window. These features are implemented using interfaces provided by @kit.ArkUI and @kit.MediaKit. | Phone | |
This sample uses the RichEditor component and common ArkUI component to implement an image and text content publisher. | Phone | |
This sample describes how to implement multiple common transition animations based on basic components, common attributes, and explicit animations. | Phone | |
This sample describes five verification code scenarios: displaying the cursor in the text box, adding a horizontal bar at the bottom, changing the background color, selecting a verification code, and sliding a verification code. | Phone | |
This sample demonstrates the sliding effect of a bottom drawer, which is implemented using the List component. It also displays a page in immersive (full screen) mode and a dragging background map. | Phone | |
This sample demonstrates a custom canvas created with the Canvas component, featuring capabilities for selecting pen thickness, color, and opacity, as well as for drawing, zooming, and clearing. | Phone | |
This sample shows how to create interactive UI elements that allow the user to drag and drop an image, rich text, a text box, and a list. | Phone | |
This sample shows how to dynamically create a component in the declarative UI. | Phone | |
This sample shows how to complex, smooth scrolling pages that ensure no frame drops during page transitions or scrolling. | Phone | |
This sample implements the function of automatically switching between landscape and portrait modes during video playback. | Phone | |
This sample shows how to use FullScreenLaunchComponent to launch the atomic service in an embedded manner. | Phone | |
Based on the default UI scanning capability and barcode image generation capability of Scan Kit, this sample implements the common scanning and acceptance and payment functions in mobile payment apps. | Phone | |
This sample implements the nested hybrid layout of the Grid, List, and Swiper components. | Phone | |
This sample implements the functions of exchanging and deleting list items. | Phone | |
This sample implements a short video app based on the adaptive layout and responsive layout, achieving one-time development for multi-device deployment. | Phone | |
This sample shows how to use a subwindow to implement a floating window and use the PiP feature to implement a small video window. | Phone | |
This sample demonstrates typical animation effects that are implemented based on basic components, universal attributes, and explicit animations. | Phone | |
This sample calls APIs such as @ohos.app.ability.ConfigurationConstant to set the dark mode. | Phone | |
This sample demonstrates the switching of short videos based on the Swiper component. | Phone | |
This sample shows how to post a comment on an image by starting the system camera. | Phone | |
Based on the adaptive layout and responsive layout, the sample implements the convenient life page that is developed once and deployed on multiple devices. | Phone | |
The sample showcases a multi-image carousel feature using the Swiper component and a custom indicator. | Phone | |
This sample uses the Navigation component for navigating between pages and PromptAction for popping up dialog boxes. It simulates the login and logout scenarios, and its UI code adapts to different device models. In addition, the app's login process complies with privacy requirements and features proper navigation logic. | Phone | |
This sample shows how to use the grid layout and List component to create responsive content layouts for stock trading apps across devices, such as smartphones, foldable screens, and tablets. | Phone | |
This sample shows how to use the breakpoint listening, sidebarContainer component, and navigation component to achieve responsive layouts of content for business office apps on different devices, such as smartphones, foldable screens, and tablets. | Phone | |
This sample demonstrates the use of ForEach for rendering a long list, and contrasts it with LazyForEach, which leverages caching of list items and component reuse, to optimize the performance of long list. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to display the web pages in an instant manner by using pre-rendering. | Phone | |
This sample shows how to use the Web component to preview local and online PDF files. The Tabs container component contains two independent TabContent subcomponents, which are used to preview local PDF files and online PDF files respectively. | Phone | |
This sample describes how to bind a custom menu to a tappable element (hyperlink or image) on the web page. | Phone | |
Based on the application startup capabilities, this sample implements scenarios such as jumping between the web page and ArkTS page, jumping to applications and details page in AppGallery from the web page. | Phone | |
Based on HTML5 games, this sample uses the ArkUI component <button> to implement basic game control. | Phone | |
This sample shows how to redirect between an HTML5 page and an ArkTS native page based on the ArkUI framework and web. | Phone | |
This sample shows how to set and obtain the user agent using ArkTS and the Web component. | Phone | |
This sample shows how to start the native camera on an HTML page to take a photo and obtain the returned photos. | Phone | |
This sample shows how to use the same-level rendering of ArkWeb. The native components of the system are directly rendered to the front-end HTML5 page. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by @ohos.file.picker, @ohos.file.photoAccessHelper and @ohos.file.fs to select and save documents, select and view photos in the system album, and select and play videos. | Phone | |
File copy is a common scenario in application development. To copy files, you can either read and write all content of a file directly or use the buffer to read and write the file for multiple times. The former is easy to use, but the memory usage is high in large file copy scenarios, affecting application performance. The latter uses less memory usage, but the programming is more complex. | Phone | |
This sample shows how to use the interfaces provided by the third-party libraries @ohos.file.fs and @ohos/commons-compress to compress and decompress files in ZIP, GZIP, TAR, and 7Z formats in different paths. | Phone | |
This sample shows how to use APIs for obtaining the storage information of an app and a file system. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows the layout and usage of service widgets in a JS project. The widget content display is developed based on one-time development and multi-device deployment to implement multi-device adaptation. | Phone | |
This sample shows how to develop a calculator model using the ArkTS widgets. | Phone | |
This sample shows how to develop a simple game widget based on the stage model. | Phone | |
This sample demonstrates how to use the router, call, and message events, as well as timed updates, to update widget information. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates how to use the input method framework to develop a custom edit box. You can bind an input method app, enter text through the app, and display or hide the input method. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by the @ohos.i18n module to implement functions such as calendar display, character type recognition, and text breaking. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample illustrates how UI Design Kit can help you process both layered and single-layer icons, including combining the foreground and background images, and cropping, scaling, and stroking icons. | Phone, Tablet, PC/2in1, TV |
Name | Overview | Device Type |
|---|---|---|
This sample code implements the following functions provided by Account Kit for HarmonyOS: signing in with the HUAWEI ID through just one tap, silently signing in, obtaining the avatar and nickname, obtaining the mobile number, obtaining the shipping address, making minor mode–related settings, and obtaining the invoice title. | Phone, Tablet, PC/2in1, TV | |
This sample project illustrates how to use the authentication.AuthenticationController API to implement silent sign-in, how to use the functions provided by the FunctionalButton component for obtaining the avatar, mobile phone, shipping address, and invoice title, and how to enable or disable the youth mode. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates how to use APIs of Ads Kit to load and display ads in your apps. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates features such as displaying an app details page, adding an atomic service widget to the home screen, and loading HAPs on demand. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This sample project illustrates how Call Service Kit works with Push Kit and Image Kit to implement functions such as subscribing to VoipCallUiEvent, reporting incoming audio and video calls, and reporting call status changes. | Phone |
Name | Overview | Device Type |
|---|---|---|
This codelab will guide you through how to use Cloud Foundation Kit to interact with the cloud in your app. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates how to develop functions such as multi-provider sign-in, compliance verification, and player role information submission. | Phone, Tablet, PC/2in1, TV | |
This sample introduces how your game sends data to the system and obtains device status through game scene perception. | Phone, Tablet, PC/2in1 | |
Interaction Between the Game and the System Based on Scene Perception (C++) | This sample introduces how your game sends data to the system and obtains device status through game scene perception. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
Health Service Kit provides an open platform for Huawei ecosystem apps to access fitness and health data of users. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
Learn to use IAP Kit to build an app where users can buy consumables and that works with the IAP Kit's delivery acknowledgement API for repurchases. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This sample implements functions such as QR code scanning, locating bikes on a map, and live view notification. | Phone |
Name | Overview | Device Type |
|---|---|---|
Map Kit is a powerful service within the HarmonyOS ecosystem. It empowers developers to effortlessly create customized map experiences by offering robust capabilities such as personalized map display, map search, and route planning. You can easily integrate map-related functions into HarmonyOS apps or atomic services to enhance user experience. | Phone, Tablet, PC/2in1, Wearable | |
This sample describes how to use Map Kit to implement typical scenarios such as map viewing, location search, route planning, service widgets, and live caption across devices. | Phone |
Name | Overview | Device Type |
|---|---|---|
PDF Kit is a PDF file service in the HarmonyOS ecosystem | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This example shows how to use Preview Kit to preview files. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
Retrieval of system attributes via API calls based on Scenario Fusion Kit | This sample code illustrates scenario-specific APIs provided by Scenario Fusion Kit, which can be used to obtain system information and location information. | Phone, Tablet, PC/2in1, Wearable, TV |
Scenario-specific button components built based on Scenario Fusion Kit | This sample illustrates how to use scenario-specific APIs buttons provided by Scenario Fusion Kit, including quick mobile number verification, real-time mobile number verification, avatar selection, and authorization setting page display buttons. | Phone, Tablet, PC/2in1 |
Intelligent input suggestions and filling based on Scenario Fusion Kit | This sample code illustrates how to use SmartFill provided by Scenario Fusion Kit to offer scenario-specific input suggestions to realize one-tap filling of complex forms for users. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This codelab describes how to use Share Kit to share data between apps. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
Wallet Kit integrates the open capabilities of the end-to-end "chip-device-cloud" technology, providing digital passes such as car keys and transportation cards. Users can easily store these digital passes on their mobile phones for convenient use whenever needed. A user can enable a digital car key in HUAWEI Wallet to use their phone to unlock their car through Bluetooth, instead of using a physical key. A digital car key can be easily shared with others (such as family members). It will not be long before this technology is widely applied in the automotive industry of the Chinese mainland. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by the geoLocationManager class of @kit.LocationKit. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the @ohos.notificationManager APIs to set a badge on the home screen and send and obtain notifications. | Phone | |
This sample shows the features related to common events for monitoring some user operations. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by @ohos.telephony.observer to subscribe to events such as the network status, signal status, cellular data, and SIM card status and obtain the status change result. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates video playback and recording implemented on AVCodec. | Phone | |
This sample demonstrates an audio app that implements audio playback control based on AudioRenderer. | Phone | |
This sample demonstrates functions related to low-latency audio recording and playback. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates video playback and recording implemented on AVCodec. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates an app that functions as an AVSession provider. It uses @ohos.multimedia.avsession to implement custom information exchange between the provider and Media Controller. | Phone | |
This sample uses the AVCastPicker component to implement the function of switching audio output devices during a call and uses the customPicker parameter to customize icons for audio output devices. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to start the system camera to take a photo and return it to the app. | Phone | |
This sample demonstrates the preview and photographing functions of a camera app. | Phone | |
This sample demonstrates the use of Camera Kit to customize a camera and use the camera to record videos through AVRecorder. This sample demonstrates a custom camera through Camera Kit and records video with AVRecorder. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample uses the @ohos.multimedia.image and @ohos.file.photoAccessHelper APIs to obtain and crop an image. | Phone | |
This sample uses the interfaces provided by @ohos.multimedia.image to compress images using the binary reduction method. | Phone | |
This sample describes how to set an adaptive background color based on the icon main color. | Phone | |
Converting the Background Color in Line with the Theme using colorPicker | This sample describes how to use the image library and colorPicker in the EffectKit library to pick the color of the target image, use the obtained color as the background gradient color, and use the Swiper component to rotate images. | Phone |
The deep copy of PixelMap is often involved in image development. In this sample, the readPixelsToBuffer method of PixelMap is used to implement the deep copy. | Phone | |
This sample uses Pen and Path of the Drawing module in conjunction with the NodeContainer component to implement the handwritten drawing feature. | Phone | |
This sample describes how to add watermarks to the page background during photo saving and photo shooting. | Phone |
Name | Overview | Device Type |
|---|---|---|
The core function of video playback is to convert video data into visible signals, play the signals through output devices, and manage the playback process. This document outlines the development for scenarios such as full-process video playback, video switching, and looping. | Phone | |
This sample shows how to use the libohcamera.so interface to implement a series of camera functions, including preview, photographing, recording, switching between front and rear cameras, as well as focus and exposure control. | Phone | |
This sample demonstrates the feature of playing a video while caching it. | Phone |
Name | Overview | Device Type |
|---|---|---|
Based on Ringtone Kit (ringtone service), it provides the function of setting ringtones. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample code demonstrates how to integrate "scan-to-access" to redirect users to a specific in-app service page in just one step and use Scan Kit's functions of recognizing, scanning, and generating barcodes, including image-based barcode recognition, barcode scan by default UI, barcode scan by custom UI, and barcode image generation. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample uses the interfaces provided by @ohos.zlib and @ohos.fileio to add, zip, and unzip files. | Phone | |
This sample shows how to use the APIs provided by @ohos.request to create upload and download tasks. The HTTP File Server (HFS) acts as the server to upload and download files and query tasks. | Phone | |
This sample shows the basic device management (non-system feature) modules that do not require complex functionality display. | Phone | |
This sample shows how to register an account, log in to an app using the registered account, and set account information. | Phone | |
This sample demonstrates the compression and decompression features. It compresses a string into a file. It also decompresses the file to read and display the string. | Phone | |
This sample uses the PasteButton component and the interfaces provided by @ohos.pasteboard to implement the basic copy and paste functions of the pasteboard. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample code illustrates how to use APIs of the navigation information service and mobility distributed engine service. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by wifiManager to obtain WLAN information. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by the Cipher object of cryptoFramework to implement encryption and decryption using the RSA and AES algorithms. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by the @ohos.security.cert module to verify signature data. | Phone |
Name | Overview | Device Type |
|---|---|---|
Provides business risk intelligent detection for anti-cheating, anti-fraud, and violation check. | Phone, Tablet | |
This sample code illustrates how to obtain a device token in an app to check the status of the app on the device. | Phone, Tablet, PC/2in1, Wearable, TV | |
This sample code illustrates how to obtain the system integrity check and URL check results in an app. | Phone, Tablet, PC/2in1 | |
Provides the TrustedAppService function to implement image security verification and location security verification, preventing images or location data obtained by apps from being tampered with. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
A distributed video player with a live video playback interface is developed in ArkTS. | Phone |
Name | Overview | Device Type |
|---|---|---|
This codelab illustrates how to implement functions for scanning files in the media library directory and app sandbox directory through Enterprise Data Guard Kit. | PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by @ohos.net.http to initiate an HTTP request based on the URL and related configuration. | Phone | |
This sample shows how to query network details, resolve domain names, and listen for network status. | Phone | |
Cross-Process Communication by Listening to 127.0.0.1 Through Socket | This sample showcases cross-process communication by listening to 127.0.0.1 through socket. | Phone |
This sample shows how to use PerformanceTiming() to obtain detailed timing information about each phase in an HTTP data request process in a table. | Phone | |
This sample shows how to use the APIs provided by the request module to listen for and manage the download progress and status of multiple files. | Phone | |
Remote communication platform (RCP) provides network data request functionalities. | Phone |
Name | Overview | Device Type |
|---|---|---|
Offers a solution that enhances network performance through acceleration, awareness, and prediction capabilities. By coordinating software, hardware, chips, devices, pipes, and cloud resources, it optimizes network resource allocation for a more reliable, smoother, and faster Internet experience. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This codelab describes how to use the FIDO password-free identity verification capability provided by HarmonyOS. | Phone, Tablet, PC/2in1 | |
This codelab describes how to use the IFAA password-free identity verification capability provided by HarmonyOS. | Phone, Tablet, PC/2in1 | |
This codelab describes how to use the SOTER password-free identity verification capability provided by HarmonyOS. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This example shows how to use the Pen Kit capability to implement the application integrated handwriting function. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the loggers of the HiLog system so that your app or service can output logs based on the specified level, ID, and string format, helping you understand the running status of your app or service and better debug it. | Phone | |
This sample shows how to use hiAppEvent to obtain the last app exception information, which can be app crash or suspension. | Phone | |
This sample shows how to use the @ohos.hidebug API to obtain the memory usage of an application. | Phone |
Name | Overview | Device Type |
|---|---|---|
Remote Communication Kit is a network request service in the HarmonyOS ecosystem. It provides convenient network request capabilities for you to customize network request functions. You can easily integrate functions related to network requests into HarmonyOS apps to improve user experience. | Phone |
Name | Overview | Device Type |
|---|---|---|
Service Collaboration Kit provides the capability of multi-device collaboration based on the same account. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This codelab enables apps to add its icon to the status bar based on Status Bar Extension Kit. | PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the unit test framework. The code component repository arkXtest of the automatic test framework is used. If log printing and debugging are required, the log printing API @ohos.hilog needs to be introduced. | Phone | |
This sample shows how to use the unit test framework. The UiTest API @ohos.UiTest has to be introduced. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to perform facial authentication and fingerprint authentication, use the password vault for automatic password filling, and prevent screen capture or recording in the app UIs involving password input. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use Wear Engine to obtain the list of connected wearable devices and interact with the wearable app. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample, based on the Native C++ template, uses OpenGL (OpenGL ES) API calls to draw a 3D shape (tetrahedron) and render it on the XComponent of the page. | Phone, Tablet | |
This sample shows how to use dlopen to load a .so library within a TaskPool thread and how to use the native Rawfile APIs to manipulate the rawfile directory and files in the directory. | Phone | |
This sample shows how to use the native XComponent interface to obtain a NativeWindow instance, obtain the layout/event information, register an event callback, draw shapes on the page through OpenGL/EGL, and render YUV images. | Phone | |
This sample shows how to use DevEco Studio to create a native C++ app, pass ArkTS data (of basic data types) to native for processing, and return the result to ArkTS. | Phone | |
This sample uses the producer-consumer pattern to illustrate the development of native multithreading and inter-thread communication. | Phone | |
This sample shows how to use the Drawing module to create a bitmap, which is subsequently rendered onto the XComponent using double buffering via NativeWindow. | Phone | |
This example demonstrates how to pass native progress information to ArkTS in a download scenario. | Phone | |
This sample describes how to save images on the network and those in the rawfile to the application sandbox in native mode. | Phone | |
This sample describes how to customize animations by using XComponent and Vsync events. | Phone |
Name | Overview | Device Type |
|---|---|---|
This example shows the ability to convert image information to character information. | Phone, Tablet, PC/2in1 | |
This example shows the AI capability of detecting faces in images and returning various data. | Phone, Tablet, PC/2in1 | |
This example shows the AI capability of identifying and extracting subjects in images, helping developers detect foreground objects and separate foreground subjects. | Phone, Tablet, PC/2in1 | |
This example shows the AI capability of comparing faces in two images and determining whether the faces are the same person. | Phone, Tablet, PC/2in1 | |
This example demonstrates the AI capability of identifying prominent target objects in an image. | Phone, Tablet, PC/2in1 | |
This example demonstrates the AI capability to recognize key bone points in a portrait. | Phone, Tablet, PC/2in1 | |
This sample shows how to use the APIs provided by @ohos.multimedia.camera (camera management) and textRecognition (text recognition) to recognize and extract text in images. | Phone |
Name | Overview | Device Type |
|---|---|---|
This example shows the AI capability of converting text information into voice and playing it. | Phone, Tablet, PC/2in1 | |
This example shows the AI capability of converting audio information into text. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
Intents Kit for HarmonyOS defines standards for intents, linking functions of apps or atomic services. It helps you intelligently distribute functions of apps or atomic services to system access points. This process is called smart distribution. The system access points include Celia Chat, Celia Search, and Celia Suggestions.The following figure shows the relationships among system access points, Intents Kit, and the HarmonyOS ecosystem. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates the AI capabilities of CANN Kit and shows how to run AI models for image classification. | Phone, Tablet, PC/2in1, TV |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the ArkTS APIs provided by MindSporeLite to build an app for classifying images on a device. | Phone |
Name | Overview | Device Type |
|---|---|---|
Natural Language Kit provides multiple basic capabilities related to text semantic understanding, helping you better process and analyze text data. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
Based on the scenario-based voice capability, AI models are provided to read text content aloud. | Phone, Tablet, PC/2in1 | |
Based on the scenario-based voice service capability, this example provides the service of identifying audio files as texts. | Phone, Tablet, PC/2in1 |
Name | Overview | Device Type |
|---|---|---|
In this example, the liveness detection and silent liveness detection are used to verify whether a user is a real live person. | Phone, Tablet | |
This example shows the multi-certificate structured identification service. | Phone, Tablet | |
In this example, the provides the service of taking documents and converting them to HD scanned copies. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This example displays the recognized point cloud information, plane information, etc. on the screen by calling the AR engine service interface and combining XComponent and OpenGL/EGL. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample describes how to smoothly refresh a page. | Phone |
Name | Overview | Device Type |
|---|---|---|
This sample demonstrates the APIs in @ohos.graphics.scene, one of the 3D engine modules. Images rendered by the 3D engine are displayed in the Component3D component. | Phone |
Name | Overview | Device Type |
|---|---|---|
Graphics Accelerate Kit - Frame Generation Example of OpenGL ES (C++) | The frame generation capability is provided in graphics rendering scenes based on frame generation APIs offered by Graphics Accelerate Kit. | Phone, Tablet |
Graphics Accelerate Kit - Frame Generation Example of Vulkan (C++) | The frame generation capability is provided in graphics rendering scenes based on APIs offered by Graphics Accelerate Kit using Vulkan. | Phone, Tablet |
The adaptive buffer resolution (ABR) capability is provided in graphics rendering scenes based on ABR APIs offered by Graphics Accelerate Kit. | Phone, Tablet | |
This sample code illustrates how to implement the OpenGTX capability in graphics rendering scenes based on the OpenGTX APIs provided by Graphics Accelerate Kit. | Phone, Tablet |
Name | Overview | Device Type |
|---|---|---|
This sample shows how to use the APIs provided by XEngine Kit to perform image upscaling and adaptative VRS. | Phone, Tablet, PC/2in1, TV | |
This sample shows how to use the APIs provided by XEngine Kit to perform image upscaling and adaptative VRS. | Phone, Tablet, PC/2in1, TV | |
This sample shows how to reduce DDR bandwidth using the Subpass Shading feature. | Phone, Tablet, PC/2in1, TV |