@@ -77,6 +77,20 @@ static internal bool LibVLCLoaded
7777 {
7878 arch = Path . Combine ( ArchitectureNames . MacOS64 , Constants . Lib ) ;
7979 }
80+
81+ #if ! NET40 && ! NETSTANDARD1_1
82+ else if ( PlatformHelper . IsWindows )
83+ {
84+ arch = RuntimeInformation . ProcessArchitecture switch
85+ {
86+ Architecture . X64 => ArchitectureNames . Win64 ,
87+ Architecture . X86 => ArchitectureNames . Win86 ,
88+ Architecture . Arm64 => ArchitectureNames . WinArm64 ,
89+ _ => PlatformHelper . IsX64BitProcess ? ArchitectureNames . Win64 : ArchitectureNames . Win86
90+ } ;
91+ }
92+ #endif
93+
8094 else
8195 {
8296 arch = PlatformHelper . IsX64BitProcess ? ArchitectureNames . Win64 : ArchitectureNames . Win86 ;
@@ -124,6 +138,27 @@ static internal bool LibVLCLoaded
124138
125139 paths . Add ( ( string . Empty , libvlcPath3 ) ) ;
126140
141+ // Add Win64 folders as fallback for WinArm64 to keep compatibility
142+ if ( arch == ArchitectureNames . WinArm64 )
143+ {
144+ var fallbackLibvlcDirPath1 = Path . Combine ( Path . GetDirectoryName ( libvlcAssemblyLocation ) ! ,
145+ Constants . LibrariesRepositoryFolderName , ArchitectureNames . Win64 ) ;
146+
147+ var fallbackLibvlccorePath1 = LibVLCCorePath ( fallbackLibvlcDirPath1 ) ;
148+ var fallbackLibvlcPath1 = LibVLCPath ( fallbackLibvlcDirPath1 ) ;
149+ paths . Add ( ( fallbackLibvlccorePath1 , fallbackLibvlcPath1 ) ) ;
150+
151+ if ( ! string . IsNullOrEmpty ( assemblyLocation ) )
152+ {
153+ var fallbackLibvlcDirPath2 = Path . Combine ( Path . GetDirectoryName ( assemblyLocation ) ! ,
154+ Constants . LibrariesRepositoryFolderName , ArchitectureNames . Win64 ) ;
155+
156+ var fallbackLibvlccorePath2 = LibVLCCorePath ( fallbackLibvlcDirPath2 ) ;
157+ var fallbackLibvlcPath2 = LibVLCPath ( fallbackLibvlcDirPath2 ) ;
158+ paths . Add ( ( fallbackLibvlccorePath2 , fallbackLibvlcPath2 ) ) ;
159+ }
160+ }
161+
127162 if ( PlatformHelper . IsMac )
128163 {
129164 var libvlcPath4 = Path . Combine ( Path . Combine ( Path . GetDirectoryName ( libvlcAssemblyLocation ) ! ,
0 commit comments