Author Topic: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll  (Read 2756 times)

0 Members and 1 Guest are viewing this topic.

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Столкнулся с проблемой файлов Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll, подозреваю что именно из-за этого у меня не работает плагин DxInput.
Никак не могу найти решение этой проблемы.
У меня Windows 10 x64, установлен Directx 12.
Версия voxcommando: 2.3.0.4

Code: [Select]
18.01.2020 1:12:01 880 found dll: D:\Voxcommando\Plugins\DxInput\DxInput.dll
18.01.2020 1:12:01 882 Loading: DxInput
18.01.2020 1:12:01 967 found dll: D:\Voxcommando\Plugins\DxInput\Microsoft.DirectX.DirectInput.dll
18.01.2020 1:12:01 973 Not a valid plugin.
System.BadImageFormatException: Не удалось загрузить файл или сборку "Microsoft.DirectX.DirectInput.dll" либо одну из их зависимостей.  не является приложением Win32. (Исключение из HRESULT: 0x800700C1)
Имя файла: 'Microsoft.DirectX.DirectInput.dll'
   в System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   в System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   в System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
   в System.Reflection.Assembly.LoadFrom(String assemblyFile)
   в VoxCommando.PluginServices.loadEnabledPlugins(String Path, List`1 whichPlugins)


18.01.2020 1:12:01 973 found dll: D:\Voxcommando\Plugins\DxInput\Microsoft.DirectX.dll
18.01.2020 1:12:01 978 Not a valid plugin.
System.BadImageFormatException: Не удалось загрузить файл или сборку "Microsoft.DirectX.dll" либо одну из их зависимостей.  не является приложением Win32. (Исключение из HRESULT: 0x800700C1)
Имя файла: 'Microsoft.DirectX.dll'
   в System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   в System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   в System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
   в System.Reflection.Assembly.LoadFrom(String assemblyFile)
   в VoxCommando.PluginServices.loadEnabledPlugins(String Path, List`1 whichPlugins)
« Last Edit: January 17, 2020, 04:30:22 PM by mozgin »

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #1 on: January 17, 2020, 05:20:40 PM »
Those errors in the log don't indicate a problem.  It's just because it is checking to see if those dlls are plugins and they are not.  the DxInput  plugin is loading properly.

Maybe we can help to find the problem if you can explain what you mean by "does not work".

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #2 on: January 18, 2020, 04:29:31 AM »
Если конкретней, то я испытываю проблемы с передачей нажатия клавиш через DxInput в Elite Dangerous.
На голосовую команду я настроил нажатие клавиши 1 и проигрывание звукового файла.
При отправке голосовой команды успешно проигрывается звуковой файл, но не нажатие клавиши.
Во время отправки голосовой команды в логе происходит следующее:
Code: [Select]
18.01.2020 13:26:45 117 Focused: EliteDangerous64
18.01.2020 13:26:45 117 addHistoryItem [vcevent] Focused.EliteDangerous64

18.01.2020 13:26:45 551 guessed text:Открыть карту галактики ?? (Голосовое управление)
18.01.2020 13:26:46 217 Something was recognized
18.01.2020 13:26:46 218 Rulename: root # Semantics: 1
18.01.2020 13:26:46 218 Group: Голосовое управление Speech: Открыть карту галактики
18.01.2020 13:26:46 228 semanticID: 105
18.01.2020 13:26:46 228 kvp: command | 105
18.01.2020 13:26:46 239 semanticID: 105
18.01.2020 13:26:46 239 kvp: command | 105
18.01.2020 13:26:46 239 alternate:Открыть карту галактики
18.01.2020 13:26:46 240 semanticID: 105
18.01.2020 13:26:46 240 kvp: prefix | Комп
18.01.2020 13:26:46 240 kvp: command | 105
18.01.2020 13:26:46 308 doCommand:Карта галактики
18.01.2020 13:26:46 309 Action claims to be threadsafe.
18.01.2020 13:26:46 463 action repeat set to: 1
18.01.2020 13:26:46 463 Action:  Sound.PlayWav
18.01.2020 13:26:46 463 Param1:D:\Voxcommando_portable\1\Открываю карту галактики.wav
18.01.2020 13:26:46 465 addHistoryItem [action] Sound.PlayWav:D:\Voxcommando_portable\1\Открываю карту галактики.wav

18.01.2020 13:26:46 474 Action INFO:
18.01.2020 13:26:46 486 Action claims to be threadsafe.
18.01.2020 13:26:46 486 action repeat set to: 1
18.01.2020 13:26:46 486 Action:  DxInput.KeyPress
18.01.2020 13:26:46 486 Param1:1
18.01.2020 13:26:46 486 addHistoryItem [action] DxInput.KeyPress:1

18.01.2020 13:26:46 486 Action from plugin: D:\Voxcommando_portable\Plugins\DxInput\DxInput.dll
18.01.2020 13:26:46 512 Action INFO: Keypress(s) emulated
18.01.2020 13:26:46 562 [plugin] Sending json request:
18.01.2020 13:26:46 562 [plugin] {"jsonrpc": "2.0", "method": "GUI.ShowNotification", "params":{"title":"Открыть карту галактики (83,8)","message":"(1 Карта галактики) "},"id": "0"}
18.01.2020 13:26:51 109 Focused: notepad++
18.01.2020 13:26:51 109 addHistoryItem [vcevent] Unfocused.EliteDangerous64

18.01.2020 13:26:51 109 addHistoryItem [vcevent] Focused.notepad++

18.01.2020 13:26:52 610 [plugin] Web Exception while calling JSON RPC:{"jsonrpc": "2.0", "method": "GUI.ShowNotification", "params":{"title":"Открыть карту галактики (83,8)","message":"(1 Карта галактики) "},"id": "0"}
System.Net.WebException: Время ожидания операции истекло
   в System.Net.HttpWebRequest.GetResponse()
   в vcPlugin.xJsonHttpCommunicator.PostRequest(String strRequest)
18.01.2020 13:26:54 115 Focused: VoxCommando

Я попробовал в блокноте выполнить команду, но в блокноте также не происходит нажатие клавиши через DxInput.
Но в блокноте работает нажатие клавиши через InputKeys.KeysDown, жаль что в Elite Dangerous нельзя использовать InputKeys.KeysDown.
« Last Edit: January 18, 2020, 04:50:33 AM by mozgin »

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2319
  • Karma: 47
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #3 on: January 18, 2020, 04:49:53 AM »
Hi mozgin,
you can try following:

swap the actions, maybe this will help
***********  get excited and make things  **********

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #4 on: January 18, 2020, 05:00:29 AM »
Я попробовал еще использовать действие SendKeys, но, оно работает только для блокнота. Для Elite Dangerous не работает.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2319
  • Karma: 47
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #5 on: January 18, 2020, 05:06:14 AM »
Did you tried to swap the actions?

I mean in following order: First the Dx.InputKeyPress action, then the Sound.Play action.
***********  get excited and make things  **********

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #6 on: January 18, 2020, 05:17:29 AM »
Да, я пробовал, но это не помогает, срабатывает только звуковой файл.

Aniv_D

  • Jr. Member
  • **
  • Posts: 42
  • Karma: 10
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #7 on: January 18, 2020, 06:57:07 AM »
можно узнать какая сборка у тебя стоит и что за версия .Net Framework установлена. просто у меня тоже стоит Вин10 х64 сборка 1809 правда. .Net 4.7.2 и без проблем работает данная версия вокса.
на ВМ машинах как то тестил и с другими сборками (1903 и выше) и тоже нормально работало. не пробовал делать проверку хранилища WinSxS?, хотя конечно я не совсем уверен что возможно дело в нём, но что то же всё же мешает правильной работе плагина... а так мог бы посоветовать попробовать аналогичную программу, которая есть в стиме (хотябы на время, пока не починится вокс), надеюсь джеймс не воспримет это за рекламу и переманивание клиентов))

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #8 on: January 18, 2020, 07:04:16 AM »
Windows 10 Pro x64
Версия: 1903
Сборка: 18362.592

Версия .Net Framework: 4.8.03752

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #9 on: January 18, 2020, 09:59:09 PM »
Hi Mozgin,

Did you try to increase the setting in the DxInput plugin for "Default KeyPress Duration (milliseconds)" ?  What do you have it set to?

Also, did you try to use keyboard emulation with any other programs, other than Elite Dangerous?

Note that the Elite Dangerous must be properly focused in order to receive keyboard emulation.  In your log it looks like Notepad++ is being focused for some reason.  Is it possible that your Windows key is pressed?  Then when the "1" key is pressed it is focusing the first item on your taskbar?

I recommend that you disable the xJson plugin, or if you are using it with Kodi sometimes, then you might want to disable the xJson setting for "OSD Notification".  The errors in your log are because VC is trying to send OSD notifications to Kodi and is unable to reach it.  This might slow things down a bit.

If you do get it working you should definitely put the keypress actions first, and then play the wav file afterwards so that it is more responsive.

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #10 on: January 19, 2020, 02:54:15 AM »
Did you try to increase the setting in the DxInput plugin for "Default KeyPress Duration (milliseconds)" ?  What do you have it set to?

1. Да, я пробовал экспериментировать с настройками плагина, на текущий момент для Default KeyPress Duration (milliseconds) установлено 20. Я пробовал устанавливать это значение равным 50 и 200.

Also, did you try to use keyboard emulation with any other programs, other than Elite Dangerous?

2. Да, я экспериментировал на notepad++, в нем работают действия InputKeys.KeysDown, SendKeys, но не работают действия DxInput.KeyPress, DxInput.KeyDown.

Note that the Elite Dangerous must be properly focused in order to receive keyboard emulation.  In your log it looks like Notepad++ is being focused for some reason.  Is it possible that your Windows key is pressed?  Then when the "1" key is pressed it is focusing the first item on your taskbar?

3. Нет, сначала фокус был на EliteDangerous64, после выполнения команды я его свернул, и фокус перешел на notepad++.

I recommend that you disable the xJson plugin, or if you are using it with Kodi sometimes, then you might want to disable the xJson setting for "OSD Notification".  The errors in your log are because VC is trying to send OSD notifications to Kodi and is unable to reach it.  This might slow things down a bit.

If you do get it working you should definitely put the keypress actions first, and then play the wav file afterwards so that it is more responsive.

4. Я сделал это, но действия DxInput.KeyPress, DxInput.KeyDown по прежнему не работают:
Code: [Select]
19.01.2020 11:24:52 77 Focused: EliteDangerous64
19.01.2020 11:24:52 78 addHistoryItem [vcevent] Focused.EliteDangerous64

19.01.2020 11:24:54 796 guessed text:Открыть карту галактики ?? (Голосовое управление)
19.01.2020 11:24:55 447 Something was recognized
19.01.2020 11:24:55 448 Rulename: root # Semantics: 1
19.01.2020 11:24:55 448 Group: Голосовое управление Speech: Открыть карту галактики
19.01.2020 11:24:55 455 semanticID: 105
19.01.2020 11:24:55 457 kvp: command | 105
19.01.2020 11:24:55 461 semanticID: 105
19.01.2020 11:24:55 461 kvp: command | 105
19.01.2020 11:24:55 461 alternate:Открыть карту галактики
19.01.2020 11:24:55 461 semanticID: 105
19.01.2020 11:24:55 461 kvp: prefix | Комп
19.01.2020 11:24:55 461 kvp: command | 105
19.01.2020 11:24:55 517 doCommand:Карта галактики
19.01.2020 11:24:55 518 Action claims to be threadsafe.
19.01.2020 11:24:55 627 action repeat set to: 1
19.01.2020 11:24:55 627 Action:  DxInput.KeyPress
19.01.2020 11:24:55 627 Param1:1
19.01.2020 11:24:55 627 addHistoryItem [action] DxInput.KeyPress:1

19.01.2020 11:24:55 628 Action from plugin: D:\Voxcommando_portable\Plugins\DxInput\DxInput.dll
19.01.2020 11:24:55 651 Action INFO: Keypress(s) emulated
19.01.2020 11:24:55 657 Action claims to be threadsafe.
19.01.2020 11:24:55 657 action repeat set to: 1
19.01.2020 11:24:55 657 Action:  Sound.PlayWav
19.01.2020 11:24:55 657 Param1:D:\Voxcommando_portable\1\Открываю карту галактики.wav
19.01.2020 11:24:55 657 addHistoryItem [action] Sound.PlayWav:D:\Voxcommando_portable\1\Открываю карту галактики.wav

19.01.2020 11:24:55 661 Action INFO:
19.01.2020 11:25:01 79 Focused: explorer
19.01.2020 11:25:01 79 addHistoryItem [vcevent] Unfocused.EliteDangerous64

UPD:
5. Я попробовал в плагине DxInput использовать действия связанные с мышью, и они работают. Значит проблема только в действиях связанных с клавиатурой.
« Last Edit: January 19, 2020, 03:04:16 AM by mozgin »

Aniv_D

  • Jr. Member
  • **
  • Posts: 42
  • Karma: 10
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #11 on: January 19, 2020, 03:38:30 AM »
заметил что в этот раз в пункте 4 в логах у тебя не было сообщения об ошибке загрузки и т.п. dll'ки.
и в связи с этим, возможно, глупый вопрос. не пробовал ли запускать вокс от админа, если не делал ранее этого. а то совсем уже вариантов не остается чего еще попробовать.

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #12 on: January 19, 2020, 03:48:20 AM »
Да, я запускаю voxcommando с правами администратора) И антивирус я отключал)
« Last Edit: January 19, 2020, 04:02:53 AM by mozgin »

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #13 on: January 20, 2020, 11:18:29 AM »
Я придумал альтернативное решение своей проблемы. Использую действие InputKeys.KeysDown, которое перехватывается сторонней программой и посылается в выбранное мной приложение (Elite Dangerous).

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7715
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #14 on: January 20, 2020, 05:16:38 PM »
That sounds like one possible solution.  What is the application that you are using, in case someone else has the same issue?
« Last Edit: January 21, 2020, 08:59:27 AM by nime5ter »

mozgin

  • Jr. Member
  • **
  • Posts: 10
  • Karma: 0
    • View Profile
Re: Ошибка Microsoft.DirectX.DirectInput.dll и Microsoft.DirectX.dll
« Reply #15 on: January 25, 2020, 05:51:59 AM »
Я использую приложение Key Manager