Samsung/Tizen-CSharp-Samples

Segmentation Error in the sample with skiasharp

sondavide opened this issue · 7 comments

When i try to deploy one sample with Skiasharp on the emulator there is the segmentation error message. I tried with SkiaSharp2DSample and PlayingWithHWInputs.
I use visual studio 2019.

Please tell your .csproj details

Hi myroot, these are the details

<Project Sdk="Tizen.NET.Sdk/1.0.9">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>tizen40</TargetFramework>
    <CopyLocalRuntimeTargetAssets>true</CopyLocalRuntimeTargetAssets>
  </PropertyGroup>

  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugType>portable</DebugType>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>None</DebugType>
  </PropertyGroup>

  <ItemGroup>
    <Folder Include="lib\" />
    <Folder Include="res\" />
  </ItemGroup>

  <ItemGroup>
    <PackageReference Include="HarfBuzzSharp" Version="1.4.6.2" />
    <PackageReference Include="SkiaSharp" Version="1.68.0" />
    <PackageReference Include="SkiaSharp.HarfBuzz" Version="1.68.0" />
    <PackageReference Include="SkiaSharp.Views" Version="1.68.0" />
    <PackageReference Include="SkiaSharp.Views.Forms" Version="1.68.0" />
    <PackageReference Include="Tizen.Wearable.CircularUI" Version="1.4.0" />
  </ItemGroup>

</Project>

Please use SkiaSharp preview version if you want to use with CircularUI 1.4.0

<PackageReference Include="SkiaSharp.Views.Forms" Version="1.68.2-preview.45" />

It is related issue and resolved on preview version
mono/SkiaSharp#1167

Please use SkiaSharp preview version if you want to use with CircularUI 1.4.0

<PackageReference Include="SkiaSharp.Views.Forms" Version="1.68.2-preview.45" />

Thank you, using this configuration the samples work:

<Project Sdk="Tizen.NET.Sdk/1.0.5">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>tizen40</TargetFramework>
    <CopyLocalRuntimeTargetAssets>true</CopyLocalRuntimeTargetAssets>
  </PropertyGroup>

  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugType>portable</DebugType>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>None</DebugType>
  </PropertyGroup>

  <ItemGroup>
    <Folder Include="lib\" />
    <Folder Include="res\" />
  </ItemGroup>

  <ItemGroup>
    <PackageReference Include="SkiaSharp.HarfBuzz" Version="1.68.2-preview.45" />
    <PackageReference Include="SkiaSharp.Views" Version="1.68.2-preview.45" />
    <PackageReference Include="SkiaSharp.Views.Forms" Version="1.68.2-preview.45" />
    <PackageReference Include="Tizen.Wearable.CircularUI" Version="1.4.0" />
  </ItemGroup>

  <ItemGroup>
    <Compile Update="MainPage.xaml.cs">
      <DependentUpon>MainPage.xaml</DependentUpon>
    </Compile>
  </ItemGroup>

  <ItemGroup>
    <EmbeddedResource Update="MainPage.xaml">
      <Generator>MSBuild:UpdateDesignTimeXaml</Generator>
    </EmbeddedResource>
  </ItemGroup>

</Project>


There is a way to use Microcharts in Tizen.Wearable project? it's a SkiaSharp wrapper

Microcharts is working on Tizen wearable