Search code examples
xamarintizenskiasharp

How to load Image using Skiasharp in Tizen watch using C#


I'm using C# Xamarin, and SkiaSharp to render image from resource folder. But I cannot get the correct image location. enter image description here

Where I can find this image when run project? I try to looking for but no result: enter image description here


Solution

  • You can get resource directory path using DirectoryInfo

    https://samsung.github.io/TizenFX/API4/api/Tizen.Applications.DirectoryInfo.html#Tizen_Applications_DirectoryInfo_Resource

    Here is a example that how to use

    https://github.com/xamarin/Xamarin.Forms/blob/b59bb767a4367240983e93ab8e1a9a050dfea23b/Xamarin.Forms.Platform.Tizen/ResourcePath.cs#L27-L30