Test: patch to add advanced d3d settings in winecfg

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
Warren Dumortier

Test: patch to add advanced d3d settings in winecfg

Post by Warren Dumortier »

Hello everybody...

My patch to add advanced d3d settings in winecfg is almost ready.
In fact, i only have to figure out how to detect video memory size to
display it when no key is set to force it or to reset. Stefan D told
me to use DirectDraw, but i wouldn't find.

So that is the last thing (except some better naming...) to do for this patch.

Everything works well and i would like some feedback.

Thanks, kind regards.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: d3d_advanced.diff
Type: text/x-patch
Size: 15150 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-us ... chment.bin>
Usurp
Level 4
Level 4
Posts: 161
Joined: Sat Apr 19, 2008 7:16 am

Re: Test: patch to add adva,ced d3d settings in winecfg

Post by Usurp »

Warren Dumortier wrote:Hello everybody...

My patch to add advanced d3d settings in winecfg is almost ready.
In fact, i only have to figure out how to detect video memory size to
display it when no key is set to force it or to reset. Stefan D told
me to use DirectDraw, but i wouldn't find.

So that is the last thing (except some better naming...) to do for this patch.

Everything works well and i would like some feedback.

Thanks, kind regards.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: d3d_advanced.diff
Type: text/x-patch
Size: 15150 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-us ... chment.bin>
Hint : won't do any good if you replace english strings by french ones into En.rc :)
Warren Dumortier

Test: patch to add adva,ced d3d settings in winecfg

Post by Warren Dumortier »

2009/4/9 Usurp <[email protected]>:
Warren Dumortier wrote:
Hello everybody...

My patch to add advanced d3d settings in winecfg is almost ready.
In fact, i only have to figure out how to detect video memory size to
display it when no key is set to force it or to reset. Stefan D told
me to use DirectDraw, but i wouldn't find.

So that is the last thing (except some better naming...) to do for this patch.

Everything works well and i would like some feedback.

Thanks, kind regards.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: d3d_advanced.diff
Type: text/x-patch
Size: 15150 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-us ... chment.bin>
Hint : won't do any good if you replace english strings by french ones into En.rc :)





What do you mean? French translations are in Fr.rc and i already did that.
As you can see the groupbox is lowered, but that's because i did in
the french .rc file, so i will have to update the english one.
Usurp
Level 4
Level 4
Posts: 161
Joined: Sat Apr 19, 2008 7:16 am

Re: Test: patch to add adva,ced d3d settings in winecfg

Post by Usurp »

What do you mean? French translations are in Fr.rc and i already did that.
As you can see the groupbox is lowered, but that's because i did in
the french .rc file, so i will have to update the english one.
Reading through http://www.winehq.org/pipermail/wine-us ... chment.bin
shows only changes to En.rc and these include french.

diff -rupN orig/programs/winecfg/En.rc new/programs/winecfg/En.rc
--- orig/programs/winecfg/En.rc 2009-03-27 19:31:22.000000000 +0100
+++ new/programs/winecfg/En.rc 2009-04-09 11:06:24.000000000 +0200
@@ -78,16 +78,39 @@ BEGIN
EDITTEXT IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED
EDITTEXT IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED

- GROUPBOX " Direct3D ",IDC_STATIC,8,95,244,49
- LTEXT "&Vertex Shader Support: ",IDC_STATIC,15,110,80,32
...
+ GROUPBOX " Direct3D ",IDC_STATIC,8,103,244,76
+ LTEXT "Support du Vertex Shader: ",IDC_STATIC,15,118,90,32
+ CONTROL "Permettre le Pixel Shader (si supporté par le matériel)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,134,230,10
Warren Dumortier

Test: patch to add adva,ced d3d settings in winecfg

Post by Warren Dumortier »

2009/4/9 Usurp <[email protected]>:
What do you mean? French translations are in Fr.rc and i already did that.
As you can see the groupbox is lowered, but that's because i did in
the french .rc file, so i will have to update the english one.
Reading through http://www.winehq.org/pipermail/wine-us ... chment.bin
shows only changes to En.rc and these include french.

diff -rupN orig/programs/winecfg/En.rc new/programs/winecfg/En.rc
--- orig/programs/winecfg/En.rc 2009-03-27 19:31:22.000000000 +0100
+++ new/programs/winecfg/En.rc  2009-04-09 11:06:24.000000000 +0200
@@ -78,16 +78,39 @@ BEGIN
    EDITTEXT    IDC_DESKTOP_WIDTH,64,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED
    EDITTEXT    IDC_DESKTOP_HEIGHT,117,68,40,12,ES_AUTOHSCROLL | ES_NUMBER | WS_DISABLED

-    GROUPBOX    " Direct3D ",IDC_STATIC,8,95,244,49
-    LTEXT       "&Vertex Shader Support: ",IDC_STATIC,15,110,80,32
...
+    GROUPBOX    " Direct3D ",IDC_STATIC,8,103,244,76
+    LTEXT       "Support du Vertex Shader: ",IDC_STATIC,15,118,90,32
+    CONTROL     "Permettre le Pixel Shader (si supporté par le matériel)",IDC_D3D_PSHADER_MODE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,15,134,230,10

Ow i'm sorry, forgot to change those strings in english...
But what about the new settings dialog?
fcmartins
Level 4
Level 4
Posts: 114
Joined: Sat Nov 01, 2008 5:48 pm

Post by fcmartins »

I did a git pull then

patch -p1 < ../WineTests/advccfg.diff

And I got:

patching file programs/winecfg/En.rc
patching file programs/winecfg/resource.h
patching file programs/winecfg/x11drvdlg.c
patch unexpectedly ends in middle of line
Hunk #6 succeeded at 635 with fuzz 1.

I'm downloading the patch from the forum and it looks indeed broken (I'm not familiar with patch format). At the end of the patch I have:

-
case WM_NOTIFY:
switch (((LPNMHDR)lParam)->code) {
case PSN_KILLACTIVE: {
Warren Dumortier

Test: patch to add adva,ced d3d settings in winecfg

Post by Warren Dumortier »

2009/4/9 fcmartins <[email protected]>:
I did a git pull then

patch -p1 < ../WineTests/advccfg.diff

And I got:

patching file programs/winecfg/En.rc
patching file programs/winecfg/resource.h
patching file programs/winecfg/x11drvdlg.c
patch unexpectedly ends in middle of line
Hunk #6 succeeded at 635 with fuzz 1.

I'm downloading the patch from the forum and it looks indeed broken (I'm not familiar with patch format). At the end of the patch I have:

-
       case WM_NOTIFY:
           switch (((LPNMHDR)lParam)->code) {
               case PSN_KILLACTIVE: {





What patch from the forum? I've attached the patch to my mail...
And just before sending it it patched successfully with latest git.
fcmartins
Level 4
Level 4
Posts: 114
Joined: Sat Nov 01, 2008 5:48 pm

Post by fcmartins »

The wine users forum and the mailing list are somewhat integrated. I suppose you are subscribed to the wine users mailing list. I am not, I only see messages in the forum (which includes automatically those of the list). So the forum patch is your patch, but it seems broken.
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

Test: patch to add adva,ced d3d settings in winecfg

Post by austin987 »

On Thu, Apr 9, 2009 at 12:14 PM, fcmartins <[email protected]> wrote:
I did a git pull then

patch -p1 < ../WineTests/advccfg.diff

And I got:

patching file programs/winecfg/En.rc
patching file programs/winecfg/resource.h
patching file programs/winecfg/x11drvdlg.c
patch unexpectedly ends in middle of line
Hunk #6 succeeded at 635 with fuzz 1.

I'm downloading the patch from the forum and it looks indeed broken (I'm not familiar with patch format). At the end of the patch I have:

-
       case WM_NOTIFY:
           switch (((LPNMHDR)lParam)->code) {
               case PSN_KILLACTIVE: {





Try getting it from the mailing list archive;
http://www.winehq.org/pipermail/wine-de ... 74677.html

--
-Austin
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

Test: patch to add adva,ced d3d settings in winecfg

Post by austin987 »

On Thu, Apr 9, 2009 at 4:28 AM, Warren Dumortier <[email protected]> wrote:
Hello everybody...

My patch to add advanced d3d settings in winecfg is almost ready.
In fact, i only have to figure out how to detect video memory size to
display it when no key is set to force it or to reset. Stefan D told
me to use DirectDraw, but i wouldn't find.

So that is the last thing (except some better naming...) to do for this patch.

Everything works well and i would like some feedback.

Thanks, kind regards.



Gives some compiler warnings here:
-limits -Wpointer-arith -g -O2 -o x11drvdlg.o x11drvdlg.c
x11drvdlg.c: In function ‘d3d_advanced_settings_save’:
x11drvdlg.c:451: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c: In function ‘d3d_advanced_settings_reset’:
x11drvdlg.c:463: warning: passing argument 1 of ‘SetDlgItemTextA’
makes pointer from integer without a cast
x11drvdlg.c:465: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:465: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c:466: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast
x11drvdlg.c:468: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:469: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast
x11drvdlg.c:471: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:472: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast


Other than that, and the comments Juan and others pointed out, looks good.

--
-Austin
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

Test: patch to add adva,ced d3d settings in winecfg

Post by austin987 »

On Thu, Apr 9, 2009 at 5:32 PM, Austin English <[email protected]> wrote:
On Thu, Apr 9, 2009 at 4:28 AM, Warren Dumortier <[email protected]> wrote:
Hello everybody...

My patch to add advanced d3d settings in winecfg is almost ready.
In fact, i only have to figure out how to detect video memory size to
display it when no key is set to force it or to reset. Stefan D told
me to use DirectDraw, but i wouldn't find.

So that is the last thing (except some better naming...) to do for this patch.

Everything works well and i would like some feedback.

Thanks, kind regards.



Gives some compiler warnings here:
-limits -Wpointer-arith  -g -O2  -o x11drvdlg.o x11drvdlg.c
x11drvdlg.c: In function ‘d3d_advanced_settings_save’:
x11drvdlg.c:451: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c: In function ‘d3d_advanced_settings_reset’:
x11drvdlg.c:463: warning: passing argument 1 of ‘SetDlgItemTextA’
makes pointer from integer without a cast
x11drvdlg.c:465: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:465: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c:466: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast
x11drvdlg.c:468: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:469: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast
x11drvdlg.c:471: warning: passing argument 1 of ‘SendMessageA’ makes
pointer from integer without a cast
x11drvdlg.c:472: warning: passing argument 1 of ‘SendDlgItemMessageA’
makes pointer from integer without a cast


Other than that, and the comments Juan and others pointed out, looks good.

--
-Austin
Compiling under 64-bit is bit more verbose:
/usr/lib/gcc-snapshot/bin/gcc -c -I. -I. -I../../include
-I../../include -D_REENTRANT -fPIC -Wall -pipe -fno-strict-aliasing
-Wdeclaration-after-statement -Wwrite-strings -Wtype-limits
-Wpointer-arith -g -O2 -o x11drvdlg.o x11drvdlg.c
x11drvdlg.c: In function 'd3d_advanced_settings_save':
x11drvdlg.c:451: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c: In function 'd3d_advanced_settings_reset':
x11drvdlg.c:463: warning: passing argument 1 of 'SetDlgItemTextA'
makes pointer from integer without a cast
../../include/winuser.h:4943: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:465: warning: passing argument 1 of 'SendMessageA' makes
pointer from integer without a cast
../../include/winuser.h:4908: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:465: warning: ISO C90 forbids mixed declarations and code
x11drvdlg.c:466: warning: passing argument 1 of 'SendDlgItemMessageA'
makes pointer from integer without a cast
../../include/winuser.h:4904: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:468: warning: passing argument 1 of 'SendMessageA' makes
pointer from integer without a cast
../../include/winuser.h:4908: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:469: warning: passing argument 1 of 'SendDlgItemMessageA'
makes pointer from integer without a cast
../../include/winuser.h:4904: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:471: warning: passing argument 1 of 'SendMessageA' makes
pointer from integer without a cast
../../include/winuser.h:4908: note: expected 'HWND' but argument is of
type 'int'
x11drvdlg.c:472: warning: passing argument 1 of 'SendDlgItemMessageA'
makes pointer from integer without a cast
../../include/winuser.h:4904: note: expected 'HWND' but argument is of
type 'int'
LD_LIBRARY_PATH="../../libs/wine:$LD_LIBRARY_PATH" ../../tools/wrc/wrc
--nostdinc -I. -I. -I../../include -I../../include -fowinecfg.res
winecfg.rc
../../tools/winegcc/winegcc -m64 -B../../tools/winebuild -mwindows
appdefaults.o audio.o drive.o drivedetect.o driveui.o libraries.o
main.o theme.o winecfg.o x11drvdlg.o winecfg.res -o winecfg.exe.so
-luuid -lcomdlg32 -lcomctl32 -lshell32 -lole32 -lwinmm -lshlwapi
-luxtheme -luser32 -lgdi32 -ladvapi32 -lkernel32
../../libs/port/libwine_port.a

--
-Austin
fcmartins
Level 4
Level 4
Posts: 114
Joined: Sat Nov 01, 2008 5:48 pm

Re: Test: patch to add adva,ced d3d settings in winecfg

Post by fcmartins »

austin987 wrote: Try getting it from the mailing list archive;
http://www.winehq.org/pipermail/wine-de ... 74677.html
Nope, I get the same file with 353 lines. Could you email it to me ([email protected]), please?

Thanks,
Fernando
fcmartins
Level 4
Level 4
Posts: 114
Joined: Sat Nov 01, 2008 5:48 pm

Post by fcmartins »

I've applied the patch Austin sent me (thanks) agains 1.1.19. There is only a loose French label in the Graphics tab ("Permettre le Pixel Shader...", which I guess is the one reported before.

I think there are a few bugs (not necessarily caused by the patch):
- the Applications Listbox is not correctly displayed: it misses the recessed effect
- the Windows version is not set by default AND winecfg does not keep it

Also, when adding an application, there is a stray bar displayed on the middle-left side of the listbox. but this one for sure existed already in 1.1.18.

I think there is also a tiny-tiny usability issue: for a normal user, there is no difference between the settings in the Direct3D section and the Advanced Button settings, i.e., all of them are likely to be perceived as advanced, anyway. It could be relabeled "Other settings", but it's not really relevant.

Since there is no help function, it could be useful to point the user to http://wiki.winehq.org/UsefulRegistryKeys for further explanations.
[/img]
loltsy
Level 2
Level 2
Posts: 20
Joined: Sat Jun 21, 2008 7:31 am

Post by loltsy »

fcmartins wrote: I think there are a few bugs (not necessarily caused by the patch):
- the Windows version is not set by default AND winecfg does not keep it
Looks like a regression in 1.1.19 since it happens with or without any patches.

Code: Select all

59148d0bb549ff8690f15f14571a715e3fdd43a5 is first bad commit
commit 59148d0bb549ff8690f15f14571a715e3fdd43a5
Author: Nikolay Sivov <[email protected]>
Date:   Tue Apr 7 12:15:21 2009 -0400

    comctl32/listview: Implement delayed header creation for ListView control.

:040000 040000 917d3c197548165028394f45e22b6d32632f36cd 3df9c0746fceb9202daab94828b78177e4f4c176 M      dlls
austin987
Wine Developer
Wine Developer
Posts: 2383
Joined: Fri Feb 22, 2008 8:19 pm

Test: patch to add advanced d3d settings in winecfg

Post by austin987 »

On Sun, Apr 12, 2009 at 12:00 PM, loltsy <[email protected]> wrote:
fcmartins wrote:
I think there are a few bugs (not necessarily caused by the patch):
- the Windows version is not set by default AND winecfg does not keep it
Looks like a regression in 1.1.19 since it happens with or without any patches.


Code:
59148d0bb549ff8690f15f14571a715e3fdd43a5 is first bad commit
commit 59148d0bb549ff8690f15f14571a715e3fdd43a5
Author: Nikolay Sivov <[email protected]>
Date:   Tue Apr 7 12:15:21 2009 -0400

   comctl32/listview: Implement delayed header creation for ListView control.

:040000 040000 917d3c197548165028394f45e22b6d32632f36cd 3df9c0746fceb9202daab94828b78177e4f4c176 M      dlls








File a bug at http://bugs.winehq.org

--
-Austin
Locked