Search found 14 matches

by mikegl
Mon Sep 02, 2019 8:10 pm
Forum: C++ Development
Topic: Enabling Stencil test
Replies: 2
Views: 93

Re: Enabling Stencil test

Thank you for the help, I have done this in OpenGL before:
Enabling/disabling the stencil buffer test is an OpenGL command: glEnable(GL_STENCIL_TEST) See https://www.khronos.org/registry/OpenGL ... able.xhtml
but I will check out the rest you have suggested.
by mikegl
Sun Sep 01, 2019 5:58 pm
Forum: C++ Development
Topic: Enabling Stencil test
Replies: 2
Views: 93

Enabling Stencil test

Hello, because stencil testing is not by default supported for some frameworks, I would like to ask if there is a need to do it for wxGLCanvas. I have only found that there is an attribute to set up the stencil buffer size but I didn't found anything about how (or if) to enable the stencil test.
by mikegl
Thu Aug 29, 2019 3:27 pm
Forum: C++ Development
Topic: Catching SHIFT + CTRL at the same time
Replies: 6
Views: 116

Re: Catching SHIFT + CTRL at the same time

Yes, this worked, too. Great thank you very much =D>
by mikegl
Thu Aug 29, 2019 1:31 pm
Forum: C++ Development
Topic: Catching SHIFT + CTRL at the same time
Replies: 6
Views: 116

Re: Catching SHIFT + CTRL at the same time

I am trying to catch the WXK_SHIFT + wxMOD_CONTROL key event at the same time. Have you tried something like this? if ( event.ControlDown() && event.ShiftDown() ) No, I didn't because here https://docs.wxwidgets.org/trunk/classwx_keyboard_state.html#a44b1e849563ebf43e073915a447e4aa5 stands that: Not...
by mikegl
Thu Aug 29, 2019 12:24 pm
Forum: C++ Development
Topic: Catching SHIFT + CTRL at the same time
Replies: 6
Views: 116

Re: Catching SHIFT + CTRL at the same time

Thank you, I have changed all to wxMOD_..., but the following code is still not working. I have tried to change the event.GetKeyCode() == WXK_SHIFT with event.GetModifiers() == wxMOD_SHIFT..., too. if ((event.GetKeyCode() == WXK_SHIFT) && (event.GetModifiers() == wxMOD_CONTROL)) mbUpDownCam = true; ...
by mikegl
Wed Aug 28, 2019 11:54 pm
Forum: C++ Development
Topic: Catching SHIFT + CTRL at the same time
Replies: 6
Views: 116

Catching SHIFT + CTRL at the same time

Hello, I am trying to catch the key commands (events) SHIFT + CONTROL at the same time to set a flag. While I am executing the following code, it is not working. Trying to catch the SHIFT and CTRL commands separately it works fine, but that is not what I want to achieve. if ((event.GetKeyCode() == W...
by mikegl
Mon Aug 05, 2019 3:43 pm
Forum: C++ Development
Topic: Restrict mouse pointer to area of GLCanvas
Replies: 2
Views: 85

Re: Restrict mouse pointer to area of GLCanvas

Thank you for the links and help I will take a look for this solution you provided. Maybe I will change the logic I had at first considered. EDIT: Thank you again T-Rex, the solution wrapping the win ops in a separate class was awesome this solved my problem. I created a Windows class and in future,...
by mikegl
Mon Aug 05, 2019 1:11 pm
Forum: C++ Development
Topic: Restrict mouse pointer to area of GLCanvas
Replies: 2
Views: 85

Restrict mouse pointer to area of GLCanvas

Hello, I want to do the following: 1. A user presses CTRL+F10 and the mouse cursor moved to the center of GLCanvas 2. The cursor gets transparent while it gets moved inside GLCanvas 3. When the user moves the cursor outside of GLCanvas (e.g. outside the right border of GLCanvas), I want to restrict ...
by mikegl
Sat Aug 03, 2019 12:08 am
Forum: C++ Development
Topic: Drawing 3D coordinate system axis within GLCanvas
Replies: 2
Views: 107

Re: Drawing 3D coordinate system axis within GLCanvas

Thank you very much, I already thought so :D
by mikegl
Fri Aug 02, 2019 10:34 pm
Forum: C++ Development
Topic: Drawing 3D coordinate system axis within GLCanvas
Replies: 2
Views: 107

Drawing 3D coordinate system axis within GLCanvas

Hello, is it possible to draw the following coordinate system axis (with labels) in GLCanvas using wxWidgets or is it only possible with OpenGL drawing operations?. I would like to embed this left down in the GLCanvas area and if the area gets rotated or pitched the coordinate system axis should do ...
by mikegl
Fri Jul 12, 2019 7:37 pm
Forum: C++ Development
Topic: Auto resize frames and content
Replies: 6
Views: 129

Re: Auto resize frames and content

Awesome thank you that did the job (In your code I had only to replace mainSizer->Add(glCanvas, 0) with btn because I got an error of adding the same window twice, but I go the idea) :). In addition, thank you for your quick help.
by mikegl
Fri Jul 12, 2019 5:35 pm
Forum: C++ Development
Topic: Auto resize frames and content
Replies: 6
Views: 129

Re: Auto resize frames and content

I have removed the event handling for the size but still,it doesn't work. Here is my code which handles the sizer: GLFrame::GLFrame(wxWindow* parent, const std::wstring& title, const wxPoint& pos, const wxSize& size) :wxFrame(parent, wxID_ANY, title, pos, size, wxDEFAULT_FRAME_STYLE) { wxBoxSizer* h...
by mikegl
Fri Jul 12, 2019 4:42 pm
Forum: C++ Development
Topic: Auto resize frames and content
Replies: 6
Views: 129

Re: Auto resize frames and content

Ok Thank you I have managed to get the minimal size using the SetSizeHints, but when I want to do this in OnSize to handle the wxEVT_SIZE I cannot expand the window. Nonetheless, I will read through your provided links and hope get it fixed. Yes, I know HTML and as I know sizers are getting implemen...
by mikegl
Fri Jul 12, 2019 2:59 pm
Forum: C++ Development
Topic: Auto resize frames and content
Replies: 6
Views: 129

Auto resize frames and content

Hello, at first this is my first post and I would like to thank the developers of wxWidgets for the awesome free GUI library which can be used for commercial purposes, too. I have created a wxFrame which contains two panels one at the left side (containing a glcanvas) and one on the right side (cont...