<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net10.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <Nullable>enable</Nullable>
    <LangVersion>latest</LangVersion>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
    <PlatformTarget>x64</PlatformTarget>
    <RuntimeIdentifier>win-x64</RuntimeIdentifier>
    <BuildNumber>0</BuildNumber>
  </PropertyGroup>

  <!-- DEBUG CONFIGURATION -->
  <PropertyGroup Condition="'$(Configuration)' == 'Debug'">
    <Optimize>false</Optimize>
    <SelfContained>false</SelfContained>
    <PublishSingleFile>false</PublishSingleFile>
    <PublishTrimmed>false</PublishTrimmed>
    <IncludeNativeLibrariesForSelfExtract>false</IncludeNativeLibrariesForSelfExtract>
    <PublishReadyToRun>false</PublishReadyToRun>
  </PropertyGroup>

  <!-- RELEASE CONFIGURATION -->
  <PropertyGroup Condition="'$(Configuration)' == 'Release'">
    <Optimize>true</Optimize>
    <EnableAVX2>true</EnableAVX2>
    <DebugType>none</DebugType>
    <DebugSymbols>false</DebugSymbols>
    <IncludeNativeLibrariesForSelfExtract>true</IncludeNativeLibrariesForSelfExtract>
    <PublishReadyToRun>true</PublishReadyToRun>
  </PropertyGroup>

  <PropertyGroup>
    <Version>1.0.0</Version>
    <InformationalVersion>$(Version).$(BuildNumber)+$(SourceRevisionId)</InformationalVersion>
    <AssemblyVersion>$(Version)</AssemblyVersion>
    <FileVersion>$(Version).$(BuildNumber)</FileVersion>
  </PropertyGroup>

    <Target Name="RemoveUnwantedFiles" AfterTargets="Publish" Condition="'$(Configuration)' == 'Release'">
    <ItemGroup>
      <FilesToDelete Include="$(PublishDir)**\*.pdb" />
      <FilesToDelete Include="$(PublishDir)**\*.lib" />
    </ItemGroup>

    <Delete Files="@(FilesToDelete)" />
  </Target>


  <ItemGroup>

    <Content Include="models/*.*">
      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
    </Content>
  </ItemGroup>
  
  <ItemGroup>
    <PackageReference Include="FFmpeg.AutoGen" Version="8.1.0" />
    <PackageReference Include="Microsoft.ML.OnnxRuntime.DirectML" Version="1.24.4" />
    <PackageReference Include="Onnxify" Version="0.3.4" />
    <PackageReference Include="OpenCvSharp4" Version="4.13.0.20260602" />
    <PackageReference Include="OpenCvSharp4.runtime.win" Version="4.13.0.20260602" />
    <PackageReference Include="Spectre.Console" Version="0.57.0" />
    <PackageReference Include="UltraFaceDotNet" Version="1.0.0.2" />
  </ItemGroup>

</Project>
