Jump to content

codeape

Members
  • Posts

    183
  • Joined

  • Last visited

Everything posted by codeape

  1. Also this lock free c++ queue could probably come in handy for Leadwerks (BSD license): http://moodycamel.com/blog/2014/a-fast-general-purpose-lock-free-queue-for-c++
  2. Looking forward to Leadwerks 5 ... some questions though: 1. Can you use Leadwerks GUI in your game or will it only be for the editor? 2. Will Windows, Linux, and Mac support be released at the same time? Thanks for the update
  3. So I think you could take a look at https://github.com/igagis/svgren it uses https://github.com/igagis/svgdom to create a SVG document object model and render it with cairo. Maybe you could use only the object model and do the rest directly in leadwerks. Maybe SVG++ could maybe be of help http://svgpp.org/.
  4. I have not opened the Leadwerks from within Steam since for ever. I always use the desktop icon but for some reason I can not even remember why I tried from within Steam.
  5. When I start Leadwerks from the Steam window Leadwerks freezes the whole desktop. If I start Leadwerks directly from the desktop it works. I am running Ubuntu 14.04.1 LTS.
  6. We also support Blender by doing this ... that is nice. I am in the same spot. I need to get more hours in to Blender.
  7. Pretty good and inexpensive Blender introduction video tutorial series (51 episodes): http://store.steampowered.com/app/373020/ Section 1 - Understanding the Interface. Chapter 01 - First encounters 5 mins Chapter 02 - Navigation 6 mins Chapter 03 - Layout Customizing 8 mins Chapter 04 - User Preference Changes 6 mins (Autodepth, Autoperspective, Addon - Layers, VBO’s.) Section 2 - 3D View. Chapter 01 - Menus, Modes and Display. 5 mins Chapter 02 - Pivot Point and 3d Manipulator 8 mins Chapter 03 - Layers and Snapping 7 mins Section 3 - Modeling Chapter 01 - Mesh Data, Object Data 7 mins Chapter 02 - Object Tools 7 mins Chapter 03 - Mesh Tools - Extrude 2 mins Chapter 04 - Mesh Tools - Bevel 1 min Chapter 05 - Mesh Tools - Subdivide 2 mins Chapter 06 - Mesh Tools - Working With Loops. 5 mins Chapter 07 - Mesh Tools - Vertex Connect 2 mins Chapter 08 - Mesh Tools - Inset. 2 mins Chapter 09 - Mesh Tools - Merging 2 mins Chapter 10 - Mesh Tools - Knife Tool 2 mins Section 4 - Modeling A Game Asset Chapter 01 - Ref Images & Traffic Cone Blockout 10 mins Chapter 02 - Traffic Cone Modeling 8 mins Chapter 03 - Normal Editing - Smooth/Hard Edges 5 mins Chapter 04 - High Res Traffic Cone 5 mins Chapter 05 - Camera Modeling 15 mins Chapter 06 - Modeling With Curves 7 mins Chapter 07 - Camera Modeling Finish 2 mins Chapter 08 - Removing NGons 4 mins Chapter 09 - Hi Res Lens And Ribbed Cable 6 mins Chapter 10 - Organizing And Naming Objects 3 mins Section 5 - UV’s. Chapter 01 - UV’s Overview 12 mins Chapter 02 - Mirror Modifier 5 mins Chapter 03 - UV Unwrapping The Base 7 mins Chapter 04 - UV Unwrapping The Cable 10 mins Chapter 05 - UV Unwrapping The Cone 9 mins Chapter 06 - UV Final Layout 8 mins Section 6 - Baking Chapter 01 - Baking Setup And Creating Images 4 mins Chapter 02 - Baking Ambient Occlusion 10 mins Chapter 03 - Baking Normal Maps 9 mins Chapter 04 - Creating The Base Color Materials 5 mins Chapter 05 - Baking The Base Color 2 mins Chapter 06 - Setting Up A Complete Material 3 mins Chapter 07 - Cord Baking And Multiple UV Sets 9 mins Chapter 08 - Baking The Camera Lens 7 mins Section 7 - 3D Painting Chapter 01 - 3D Painting Setup 6 mins Chapter 02 - Painting A Vertical Gradient 6 mins Chapter 03 - Multi Layered Painting 18 mins Chapter 04 - Worn Edges With Cavity Masking 13 mins Chapter 05 - Baking All Layers Down To 1. 7 mins Section 8 - Importing And Exporting Chapter 01 - Importing A TF2 Character 3 mins Chapter 02 - Rigging And Placing The Asset 2 mins Chapter 03 - LOD Creation 6 mins Chapter 04 - Exporting As OBJ 1 min Chapter 05 - Importing Into Team Fortress 2. 5 mins
  8. Josh, should I post this to the Bug forum? Thanks for the help by the way
  9. The XSetStandardProperties function has been superseded by XSetWMProperties.
  10. Sorry for the late answer but I have been busy with my kids I can confirm that window->takeownership work. I have changed my code to this and I can now create a new window and get the old window destroyed: if (window->KeyHit(Key::R)) { window->takeownership = true; if (window->style == Leadwerks::Window::FullScreen) { System::Print("Go Resizable"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 1024, 768, Leadwerks::Window::Resizable); } else { System::Print("Go FullScreen"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 1920, 1200, Leadwerks::Window::FullScreen); } //Create a context context = Context::Create(window); window->HideMouse(); window->SetMousePosition(context->GetWidth()/2,context->GetHeight()/2); } Thanks
  11. I want to be able to toggle between diffren windows styles (FullScreen and Resizable). For all examples I have created I have used a new project and only added the if (window->KeyHit(Key::R)) block and I create the window in App::Start() with Leadwerks::Window::Create("test", 0, 0, 1024, 768, Leadwerks::Window::Resizable); Example one. I can toggle from windowed mode to full screen mode but not back to windowed mode with this code: bool App::Loop() { //Close the window to end the program if (window->Closed()) return false; //Press escape to end freelook mode if (window->KeyHit(Key::Escape)) { if (!freelookmode) return false; freelookmode=false; window->ShowMouse(); } if (freelookmode) { //Keyboard movement float strafe = (window->KeyDown(Key:) - window->KeyDown(Key::A))*Leadwerks::Time::GetSpeed() * 0.05; float move = (window->KeyDown(Key::W) - window->KeyDown(Key::S))*Leadwerks::Time::GetSpeed() * 0.05; camera->Move(strafe,0,move); //Get the mouse movement float sx = context->GetWidth()/2; float sy = context->GetHeight()/2; Vec3 mouseposition = window->GetMousePosition(); float dx = mouseposition.x - sx; float dy = mouseposition.y - sy; //Adjust and set the camera rotation camerarotation.x += dy / 10.0; camerarotation.y += dx / 10.0; camera->SetRotation(camerarotation); //Move the mouse to the center of the screen window->SetMousePosition(sx,sy); } if (window->KeyHit(Key::R)) { if (window->style == Leadwerks::Window::FullScreen) { System::Print("Go Resizable"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 800, 600, Leadwerks::Window::Resizable); } else { System::Print("Go FullScreen"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 1920, 1200, Leadwerks::Window::FullScreen); } //Create a context context = Context::Create(window); window->HideMouse(); window->SetMousePosition(context->GetWidth()/2,context->GetHeight()/2); } Leadwerks::Time::Update(); world->Update(); world->Render(); context->Sync(false); return true; } So when I hit R i get in to full screen but when I hit R again I do not get back to windowed mode. When I hit ESC twice I get back my desktop by exiting the application. Example 2. So to test what happens behind the sceens I changed the if (window->KeyHit(Key::R)) block to this: if (window->KeyHit(Key::R)) { if (window->style == Leadwerks::Window::Titlebar) { System::Print("Go Resizable"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 1024, 768, Leadwerks::Window::Resizable); } else { System::Print("Go other size"); window->Release(); window = Leadwerks::Window::Create("test", 0, 0, 800, 600, Leadwerks::Window::Titlebar); } //Create a context context = Context::Create(window); window->HideMouse(); window->SetMousePosition(context->GetWidth()/2,context->GetHeight()/2); } Everytime I hit R I get a new window but the old window is not removed (so I get a large amount os windows). What am I doing wrong? or is this a bug?
  12. I solved it with this little code change: window = Leadwerks::Window::Create("test", 0, 0, 1024, 768, Leadwerks::Window::Resizable); The key was setting the style argument of Window::Create() to Leadwerks::Window::Resizable. The Leadwerks C++ template code looks like this: Leadwerks::Window::Create("branch"); The style argument defaults to Leadwerks::Window::Titlebar and that does apparently not play nice with SetLayout in Linux but works well in Windows.
  13. Why is this not high priority? When will it be high priority? Is there a workaround?
  14. So I have done a bunch of research for this. Some feedback. An update. Any of your new helpers that speak Xlib?
  15. Another good example is from the godot engine: https://github.com/okamstudio/godot/blob/a12c364489df586bf3cbb38f613c0615f88eaff1/platform/x11/os_x11.cpp So what are your thoughts about this problem Josh?
  16. Ok I have done some more research. A god idea is to read this: http://www.hpc.unimelb.edu.au/nec/g1ae02e/appd.html, and clean out all obsolete stuff like XSetStandardProperties (Pre X11 legacy stuff). Also XMoveResizeWindow can sometimes be ignored and we end up with no-op: http://tronche.com/gui/x/xlib/window/XMoveResizewindow.html I think this is some good hints from SDL that can interpreted like this: // Apparently, if the X11 Window is set to a 'non-resizable' window, you cannot resize it using the // XResizeWindow, thus we must set the size hints to adjust the window size. XSizeHints *sizehints = XAllocSizeHints(); long userhints; XGetWMNormalHints(display, data->xwindow, sizehints, &userhints); sizehints->min_width = sizehints->max_width = window->w; sizehints->min_height = sizehints->max_height = window->h; sizehints->flags |= PMinSize | PMaxSize; XSetWMNormalHints(display, data->xwindow, sizehints); XFree(sizehints); // WMs each have their little quirks with that. When you change the // size hints, they get a ConfigureNotify event with the // WM_NORMAL_SIZE_HINTS Atom. They all save the hints then, but they // dont all resize the window right away to enforce the new hints. // Some of them resize only after: // - A user-initiated move or resize // - A code-initiated move or resize // - Hiding & showing window (Unmap & map) // The following move & resize seems to help a lot of WMs that didn't // properly update after the hints were changed. We don't do a // hide/show, because there are supposedly subtle problems with doing so // and transitioning from windowed to fullscreen in Unity. XResizeWindow(display, data->xwindow, window->w, window->h); XMoveWindow(display, data->xwindow, window->x, window->y); XRaiseWindow(display, data->xwindow); Inspired by X11_SetWindowSize (https://hg.libsdl.org/SDL/file/3331d2f57704/src/video/x11/SDL_x11window.c#l831) The comments about Unity in that file is very interesting also since that is the only WM that Leadwerks support.
  17. I notice that the class uses XSetStandardProperties but that one has been superseded by XSetWMProperties.
  18. Ok, so you probably need to call XSetWMNormalHints before you call XMoveResizewindow. This is because some window managers may redirect window configuration requests, but ignore the resulting events and pay property changes instead. Some more info ... Page 623 in this book: https://books.google.se/books?id=2uVfJj_4AZgC&printsec=frontcover&source=gbs_ge_summary_r&cad=0#v=onepage&q&f=false This man page: http://manpages.ubuntu.com/manpages/saucy/man3/XAllocSizeHints.3.html
  19. Mmmmm True. I forgot my specs. Linux dist: $ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 14.04.2 LTS Release: 14.04 Codename: trusty Graphics card: fglrxinfo display: :0 screen: 0 OpenGL vendor string: Advanced Micro Devices, Inc. OpenGL renderer string: AMD Radeon HD 5700 Series OpenGL version string: 4.3.12798 Compatibility Profile Context 13.35.1005 A question. Will this bug be fixed soon or something that will be included when you get in to fixing the Uniform buffers and FBOs mentioned in this blog post: http://www.leadwerks.com/werkspace/blog/1/entry-1427-34-recap-and-beyond/
  20. I think this article show the differences of OpenGL and Vulcan quite well: http://www.phoronix.com/scan.php?page=article&item=khronos-vulcan-spirv&num=1 There is already a nice Vulcan debug tool in the works called GLAVE: http://www.phoronix.com/image-viewer.php?id=khronos-vulcan-spirvℑ=vulkan_announce_2_lrg
  21. The code works in Windows. When I hit the L key the window is resized to 1600x1200 from 1024x768. This is a Linux only bug. Anyone else that experiense this in Linux?
×
×
  • Create New...