{"action":"created","issue":{"url":"https://api.github.com/repos/gonutz/d3d9/issues/1","repository_url":"https://api.github.com/repos/gonutz/d3d9","labels_url":"https://api.github.com/repos/gonutz/d3d9/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/gonutz/d3d9/issues/1/comments","events_url":"https://api.github.com/repos/gonutz/d3d9/issues/1/events","html_url":"https://github.com/gonutz/d3d9/issues/1","id":154503850,"number":1,"title":"panic: calling Direct3DCreate9: The specified program requires a newer version of Windows.","user":{"login":"mzbab88","id":19152680,"avatar_url":"https://avatars.githubusercontent.com/u/19152680?v=3","gravatar_id":"","url":"https://api.github.com/users/mzbab88","html_url":"https://github.com/mzbab88","followers_url":"https://api.github.com/users/mzbab88/followers","following_url":"https://api.github.com/users/mzbab88/following{/other_user}","gists_url":"https://api.github.com/users/mzbab88/gists{/gist_id}","starred_url":"https://api.github.com/users/mzbab88/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mzbab88/subscriptions","organizations_url":"https://api.github.com/users/mzbab88/orgs","repos_url":"https://api.github.com/users/mzbab88/repos","events_url":"https://api.github.com/users/mzbab88/events{/privacy}","received_events_url":"https://api.github.com/users/mzbab88/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-12T14:56:43Z","updated_at":"2016-05-12T20:13:48Z","closed_at":null,"body":"Hello. Really glad somebody decided to do this, this will probably be priceless for me.\r\n\r\nI tried to compile samples\\rotating_quad, it compiled, but it gives me this error:\r\n\r\n```\r\npanic: calling Direct3DCreate9: The specified program requires a newer version of Windows.\r\n\r\ngoroutine 1 [running, locked to thread]:\r\npanic(0x514200, 0x12840110)\r\n\tC:/Go/src/runtime/panic.go:464 +0x326\r\nmain.check(0x25a0018, 0x12840110)\r\n\tC:/Users/User/GoPath/src/github.com/gonutz/d3d9/samples/rotating_quad/main.go:123 +0x44\r\nmain.main()\r\n\tC:/Users/User/GoPath/src/github.com/gonutz/d3d9/samples/rotating_quad/main.go:33 +0x1d8\r\n```\r\n\r\nI'm on windows 7, and I'm really puzzled by necessity of using anything newer for just calling a dll. Can you give me a hint on what to do? I'm ready to test anything for as long as it will take.\r\n\r\nProbably this will work if this program would use syscall.NewLazyDLL or syscall.MustLoadDLL instead of syscall.Syscall, at least I was told so. Here are a few links:\r\n\r\nhttp://noypi-linux.blogspot.ru/2012/04/golang-using-shared-libraries.html  Method 1 from here\r\n\r\nhttps://github.com/golang/go/wiki/WindowsDLLs Example two from here\r\n\r\nhttp://stackoverflow.com/questions/22949444/using-go-golang-to-get-windows-idle-time-getlastinputinfo-or-similar\r\n\r\nhttps://golang.org/src/syscall/dll_windows.go\r\n"},"comment":{"url":"https://api.github.com/repos/gonutz/d3d9/issues/comments/218872142","html_url":"https://github.com/gonutz/d3d9/issues/1#issuecomment-218872142","issue_url":"https://api.github.com/repos/gonutz/d3d9/issues/1","id":218872142,"user":{"login":"gonutz","id":8217337,"avatar_url":"https://avatars.githubusercontent.com/u/8217337?v=3","gravatar_id":"","url":"https://api.github.com/users/gonutz","html_url":"https://github.com/gonutz","followers_url":"https://api.github.com/users/gonutz/followers","following_url":"https://api.github.com/users/gonutz/following{/other_user}","gists_url":"https://api.github.com/users/gonutz/gists{/gist_id}","starred_url":"https://api.github.com/users/gonutz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonutz/subscriptions","organizations_url":"https://api.github.com/users/gonutz/orgs","repos_url":"https://api.github.com/users/gonutz/repos","events_url":"https://api.github.com/users/gonutz/events{/privacy}","received_events_url":"https://api.github.com/users/gonutz/received_events","type":"User","site_admin":false},"created_at":"2016-05-12T20:13:48Z","updated_at":"2016-05-12T20:13:48Z","body":"Hi there! I have encountered similar problems on two test machines lately, both fail on initialization but with different error messages. I am still trying to figure out what is happening there.\r\nFirst I thought it was because of an error in the d3d9.dll (in C:\\Windows\\System32) but that does not seem to be it.\r\nAs you can see in [the code](https://github.com/gonutz/d3d9/blob/master/IDirect3D9_windows.go#L164) I am using syscall.LoadLibrary to load the DLL. It should probably not make a difference whether you use a regular or a lazy DLL in go, it is just a matter of when the functions are loaded, they should still be there and work in any case. But I will try it anyway, just to be sure.\r\nCan you make sure that you have the latest DirectX runtime installed? And maybe check your video driver. You can use dxdiag and run their tests.\r\nAs you can see I am currently still quite puzzled myself but be assured that I am working on the problem. One goal for me with this library was that programs should run without installing DLLs as Windows usually comes with d3d9.dll pre-installed on all versions. But as long as this problem exists this goal is not met so I really appreciate your help with this :)"}}