{"action":"created","issue":{"url":"https://api.github.com/repos/iXit/Mesa-3D/issues/65","repository_url":"https://api.github.com/repos/iXit/Mesa-3D","labels_url":"https://api.github.com/repos/iXit/Mesa-3D/issues/65/labels{/name}","comments_url":"https://api.github.com/repos/iXit/Mesa-3D/issues/65/comments","events_url":"https://api.github.com/repos/iXit/Mesa-3D/issues/65/events","html_url":"https://github.com/iXit/Mesa-3D/issues/65","id":55359221,"number":65,"title":"WOLF RPG Editor (Game.exe): Black screen in GPU rendering mode","user":{"login":"kakurasan","id":10556453,"avatar_url":"https://avatars.githubusercontent.com/u/10556453?v=3","gravatar_id":"","url":"https://api.github.com/users/kakurasan","html_url":"https://github.com/kakurasan","followers_url":"https://api.github.com/users/kakurasan/followers","following_url":"https://api.github.com/users/kakurasan/following{/other_user}","gists_url":"https://api.github.com/users/kakurasan/gists{/gist_id}","starred_url":"https://api.github.com/users/kakurasan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kakurasan/subscriptions","organizations_url":"https://api.github.com/users/kakurasan/orgs","repos_url":"https://api.github.com/users/kakurasan/repos","events_url":"https://api.github.com/users/kakurasan/events{/privacy}","received_events_url":"https://api.github.com/users/kakurasan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2015-01-24T05:04:37Z","updated_at":"2016-12-10T13:53:51Z","closed_at":null,"body":"In GPU rendering mode, nothing displayed. keyboard and sound work.\nIf native Direct3D 9 is disabled, this program almost works fine (font rendering is broken in version 2.10, see https://bugs.winehq.org/show_bug.cgi?id=35205).\n- Wine log (with nine): https://onedrive.live.com/redir?resid=3F9BE5B1CD4A806C!2423&authkey=!AHji1qX4zUT07n4&ithint=file%2cxz\n- Debug log (\"wine Game.exe Test_Of_Main\", with nine): https://onedrive.live.com/redir?resid=3F9BE5B1CD4A806C!2422&authkey=!AFV9tU6rFvnTIlI&ithint=file%2ctxt\n- Wine log (without nine): https://onedrive.live.com/redir?resid=3F9BE5B1CD4A806C!2421&authkey=!AOHZKrCMj1dFgSo&ithint=file%2cxz\n- Debug log (\"wine Game.exe Test_Of_Main\", without nine): https://onedrive.live.com/redir?resid=3F9BE5B1CD4A806C!2424&authkey=!AM6V7k6ONMlJWiQ&ithint=file%2ctxt\n\nIt seems some color format values are different between wined3d and nine.\n- wined3d:\n  - 16bit color format = D3DFMT_R5G6B5\n  - 1ch/integer/8bit color format = D3DFMT_A8R8G8B8\n  - 1ch/integer/16bit color format = D3DFMT_G16R16\n  - 2ch/integer/8bit color format = D3DFMT_A8B8G8R8\n- nine (175b5b2209):\n  - 16bit color format = D3DFMT_R5G5B5\n  - 1ch/integer/8bit color format = D3DFMT_L8\n  - 1ch/integer/16bit color format = D3DFMT_L16\n  - 2ch/integer/8bit color format = D3DFMT_V8U8\n\nWOLF RPG Editor download page (Japanese): http://www.vector.co.jp/soft/dl/winnt/game/se475870.html\n\nWOLF RPG Editor uses a DirectX wrapper library called \"DX Library\" (open source). The latest version (2.10) uses DX Library 3.10f (development version, not available). version 3.10e and 3.11 are available at http://homepage2.nifty.com/natupaji/DxLib/dxolddload.html (exe files are 7-Zip archives, 7z can extract them).\n\nppa:oibaf/graphics-drivers + ppa:commendsarnex/winedri3 + iXit/Mesa-3D 175b5b2209\n"},"comment":{"url":"https://api.github.com/repos/iXit/Mesa-3D/issues/comments/266210073","html_url":"https://github.com/iXit/Mesa-3D/issues/65#issuecomment-266210073","issue_url":"https://api.github.com/repos/iXit/Mesa-3D/issues/65","id":266210073,"user":{"login":"kakurasan","id":10556453,"avatar_url":"https://avatars.githubusercontent.com/u/10556453?v=3","gravatar_id":"","url":"https://api.github.com/users/kakurasan","html_url":"https://github.com/kakurasan","followers_url":"https://api.github.com/users/kakurasan/followers","following_url":"https://api.github.com/users/kakurasan/following{/other_user}","gists_url":"https://api.github.com/users/kakurasan/gists{/gist_id}","starred_url":"https://api.github.com/users/kakurasan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kakurasan/subscriptions","organizations_url":"https://api.github.com/users/kakurasan/orgs","repos_url":"https://api.github.com/users/kakurasan/repos","events_url":"https://api.github.com/users/kakurasan/events{/privacy}","received_events_url":"https://api.github.com/users/kakurasan/received_events","type":"User","site_admin":false},"created_at":"2016-12-10T13:53:51Z","updated_at":"2016-12-10T13:53:51Z","body":"\"DX Library\" calls `IDirectDraw7::SetCooperativeLevel()` in Windows/DxGraphicsAPIWin.cpp (function `OldGraphicsInterface_Create()`). I found that nothing rendered *when `D_DDSCL_NORMAL` is specified* (if the flag is removed, the rendering works).\r\n\r\n```cxx\r\n// Doesn't work (original code)\r\nGAPIWin.DirectDraw7Object->SetCooperativeLevel( NS_GetMainWindowHandle(), D_DDSCL_NORMAL | ( WinData.UseFPUPreserve ? D_DDSCL_FPUPRESERVE : 0 ) ) ;\r\n\r\n// Works (modified code, incorrect cooplevel flag specified)\r\nGAPIWin.DirectDraw7Object->SetCooperativeLevel( NS_GetMainWindowHandle(), ( WinData.UseFPUPreserve ? D_DDSCL_FPUPRESERVE : 0 ) ) ;\r\n```\r\n\r\nSo, a workaround is to insert `return DD_OK;` to the beginning of the function `ddraw_set_cooperative_level()` in dlls/ddraw/ddraw.c (WOLF RPG Editor also works)."}}
{"actor":{"display_login":"kakurasan"}}