Gray box around video, can't play any games.
#41
Take the first build that is wrong and then do the patch manually in the reserse way.

Replace
GtkWidget *child_window = (GtkWidget*)GTK_BIN(gsFrame->GetViewport()->GetHandle());
by
GtkWidget *child_window = gtk_bin_get_child(GTK_BIN(gsFrame->GetViewport()->GetHandle()));

Replace
GdkWindow* draw_window = gtk_widget_get_window(child_window);
by
GdkWindow* draw_window = GTK_PIZZA(child_window)->bin_window;

If it is too difficult I do a branch with those change tomorrow
Reply

Sponsored links

#42
I get this error when I try to build after changing those two lines.

[ 51%] At global scope:
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
Building CXX object pcsx2/CMakeFiles/pcsx2-dev.dir/gui/AppMain.cpp.o
[ 51%] Building CXX object pcsx2/CMakeFiles/pcsx2-dev.dir/gui/ConsoleLogger.cpp.o
[ 51%] Building CXX object pcsx2/CMakeFiles/pcsx2-dev.dir/gui/CpuUsageProvider.cpp.o
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘void Pcsx2App:OhmynEmuKeyDown(wxKeyEvent&)’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:579:57: warning: statement has no effect [-Wunused-value]
DbgCon.WriteLn( "(app) Invoking command: %s", cmd->Id );
^
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘void Pcsx2App:OhmypenGsPanel()’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:942:49: error: ‘GTK_PIZZA’ was not declared in this scope
GdkWindow* draw_window = GTK_PIZZA(child_window)->bin_window;
^
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘virtual void SysExecEvent_Execute::InvokeEvent()’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:1047:57: warning: statement has no effect [-Wunused-value]
DbgCon.WriteLn( Color_Gray, "(SysExecute) received." );
^
At global scope:
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
make[2]: *** [pcsx2/CMakeFiles/pcsx2-dev.dir/gui/AppMain.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [pcsx2/CMakeFiles/pcsx2-dev.dir/all] Error 2
make: *** [all] Error 2
[ 5%] Built target translations_pcsx2_Iconized
[ 10%] Built target translations_pcsx2_Main
[ 16%] Built target Utilities
[ 19%] Built target x86emitter
[ 19%] Building CXX object pcsx2/CMakeFiles/pcsx2-dev.dir/gui/AppMain.cpp.o
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘void Pcsx2App:OhmynEmuKeyDown(wxKeyEvent&)’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:579:57: warning: statement has no effect [-Wunused-value]
DbgCon.WriteLn( "(app) Invoking command: %s", cmd->Id );
^
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘void Pcsx2App:OhmypenGsPanel()’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:942:49: error: ‘GTK_PIZZA’ was not declared in this scope
GdkWindow* draw_window = GTK_PIZZA(child_window)->bin_window;
^
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp: In member function ‘virtual void SysExecEvent_Execute::InvokeEvent()’:
/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:1047:57: warning: statement has no effect [-Wunused-value]
DbgCon.WriteLn( Color_Gray, "(SysExecute) received." );
^
At global scope:
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
cc1plus: warning: unrecognized command line option "-Wno-ignored-attributes" [enabled by default]
make[2]: *** [pcsx2/CMakeFiles/pcsx2-dev.dir/gui/AppMain.cpp.o] Error 1
make[1]: *** [pcsx2/CMakeFiles/pcsx2-dev.dir/all] Error 2
make: *** [all] Error 2
Reply
#43
Quote:/home/vvvv/Build/pcsx2/pcsx2/gui/AppMain.cpp:942:49: error: ‘GTK_PIZZA’ was not declared in this scope
GdkWindow* draw_window = GTK_PIZZA(child_window)->bin_window;

GTK_PIZZA is missing.
I think you just have to put
Code:
#include <wx/gtk/win_gtk.h> // GTK_PIZZA interface
in the head of the file
Reply
#44
Looks like that worked. It builds successfully and the gray box is gone.
Reply
#45
Then gregory will solve it tomorrow Wink


I am not sure but maybe you can test what happens if you apply only one of these changes.

So maybe you can revert:
Replace
GtkWidget *child_window = gtk_bin_get_child(GTK_BIN(gsFrame->GetViewport()->GetHandle()));
by
GtkWidget *child_window = (GtkWidget*)GTK_BIN(gsFrame->GetViewport()->GetHandle());

I don't know what these functions do but I guess gregory wants to know which of these two changes made the regression.
Reply
#46
Okay, I'll try each one separately and post the results.
Reply
#47
Looks like both changes are needed. If I only change
Replace
GtkWidget *child_window = gtk_bin_get_child(GTK_BIN(gsFrame->GetViewport()->GetHandle()));
by
GtkWidget *child_window = (GtkWidget*)GTK_BIN(gsFrame->GetViewport()->GetHandle());

pcsx2 instantly crashes after starting a game. If I change only the other line the gray box is there.
Reply
#48
The gray box is gone in latest build too after replacing those two lines, and adding that include statement! Smile
Reply
#49
Thanks for all tests. And sorry for having forgotten the include.

I can revert the code for wx2.8, however wx3.0 won't work with the old code. First of all I want the confirmation that bug exists on wx3.0. Could you build PCSX2 with wx3 support (use --help to see the option for .sh build script/otherwise there is a cmake option)?
Reply
#50
With the latest build it is not present when I use the --wx30 option. It is present when I try the build before "wx: use wx_pizza on wx2.8" using the --wx30 option.

Edit: I'm not sure if that worked properly I just checked and I didn't have libwxgtk3.0-dev installed. I'm going to try again now that I have them.
Reply




Users browsing this thread: 1 Guest(s)