Jump to content
  • entries
    942
  • comments
    5,896
  • views
    873,100

About this blog

Learn about game development technology

Entries in this blog

Networking

I spent a few days setting up a server application and attempting to implement NAT punch through. You can read the details of my adventures here. Here's what I think: I can probably get it working. There's a lot of weird hardware and configurations out there I can't realistically test. There will always be a certain failure rate which translates into angry users who I can't help. So I started to think about this backwards, by first asking what we want the user exp

Josh

Josh

Oculus Rift vs. HTC Vive: Which is the one true VR headset?

I recently picked up an Oculus Rift (CV1) in order to improve our support for this headset. It was easy to make my changes, but having the actual hardware on hand was invaluable in this process, and our support for the Rift is now much better because of this. I have now tried a total of five different VR headsets: HTC Vive Valve's duct-taped prototype that was the basis of the HTC Vive. Oculus Rift DK1 Oculus Rift DK2 Oculus Rift CV1 At one point Leadwe

Josh

Josh

Building a Zero-Overhead Renderer

The Leadwerks 4 renderer was built for maximum flexibility. The Leadwerks 5 renderer is being built first and foremost for great graphics with maximum speed. This is the fundamental difference between the two designs. VR is the main driving force for this direction, but all games will benefit. Multithreaded Design Leadwerks 4 does make use of multithreading in some places but it is fairly simplistic. In Leadwerks 5 the entire architecture is based around separate threads, which is chal

Josh

Josh

Taking Care of Business

This is about financial stuff, and it's not really your job to care about that, but I still think this is cool and wanted to share it with you. People are buying stuff on our website, and although the level of sales is much lower than Steam it has been growing. Unlike Steam, sales through our website are not dependent on a third party and cannot be endangered by flooded marketplaces, strange decisions, and other random events. Every customer I checked who used a credit card has kept it

Josh

Josh

Physically-based Rendering

An online implementation of physically-based rendering in the Khronos Github was pointed out to me by @IgorBgz90 and @shadmar. This is very useful because it's an official implementation of PBR that removes a lot of guesswork. Here is my first attempt, which is not using any cubemap reflections: And here it is with cubemap reflections added: I plan to use the real-time global illumination system to generate the reflection data, instead of using environment probes. T

Josh

Josh

Multiple Shadows

Texture arrays are a feature that allow you to pack multiple textures into a single one, as long as they all use the same format and size. In reality, this is just a convenience feature that packs all the textures into a single 3D texture. It allows things like cubemap lookups with a 3D texture, but the implementation is sort of inconsistent. In reality it would be much better if we were just given 1000 texture units to use. However, these can be used to pack all scene shadow maps into a single

Josh

Josh

Map Viewer available to subscribers

A map viewer application is now available for beta subscribers. This program will load any Leadwerks map and let you fly around in it, so you can see the performance difference the new renderer makes. I will be curious to hear what kind of results you see with this: Program is not tested with all hardware yet, and functionality is limited.

Josh

Josh

Vector Image Support

Building on the Asset Loader class I talked about in my previous blog post, I have added a loader to import textures from SVG files. In 2D graphics there are two types of image files. Rasterized images are made up of a grid of pixels. Vector images, on the other hand, are made up of shapes like Bezier curves. One example of vector graphics you are probably familiar with are the fonts used on your computer. SVG files are a vector image format that can be created in Adobe Illustrator and othe

Josh

Josh

Fun with Stateless API

Leadwerks 5 / Turbo makes extensive use of multithreading. Consequently, the API is stateless and more explicit. There is no such thing as a "current" world or context. Instead, you explicitly pass these variables to the appropriate commands. One interesting aspect of this design is code like that below works perfectly fine. See if you can work through it and understand what's going on: int main(int argc, const char *argv[]) { //Create a model ;) auto box = CreateBox(nullptr); //Cre

Josh

Josh

Textures in Vulkan

I finally got a textured surface rendering in Vulkan so we now have officially surpassed StarFox (SNES) graphics: Although StarFox did have distance fog. ? Vulkan uses a sort of "baked" graphics pipeline. Each surface you want to render uses an object you have to create in code that contains all material, texture, shader, and other settings. There is no concept of "just change this one setting" like in OpenGL. Consequently, the new renderer may be a bit more rigid than what

Josh

Josh

Vulkan Tessellation Made Practical

Now that I have all the Vulkan knowledge I need, and most work is being done with GLSL shader code, development is moving faster. Before starting voxel ray tracing, another hard problem, I decided to work one some *relatively* easier things for a few days. I want tessellation to be an every day feature in the new engine, so I decided to work out a useful implementation of it. While there are a ton of examples out there showing how to split a triangle up into smaller triangles, useful discus

Josh

Josh

Message Boxes

If were a user of BlitzMax in the past, you will love these convenience commands in Turbo Engine: int Notify(const std::wstring& title, const std::wstring& message, shared_ptr<Window> window = nullptr, const int icon = 0) int Confirm(const std::wstring& title, const std::wstring& message, shared_ptr<Window> window = nullptr, const int icon = 0) int Proceed(const std::wstring& title, const std::wstring& message, shared_ptr<Window> window = nullptr, co

Josh

Josh

Skinned Animation in Vulkan

It's been nearly a year since I made the decision to port our OpenGL renderer over to Vulkan, and it has been very difficult work, but we are getting back up to speed. I was able to get skinned animation working for the first time in Vulkan yesterday, using a slightly modified version of our original animation shader code. The system works exactly the same as in Leadwerks 4, with a few differences: Animation features are confined to the Model class only, and are no longer

Josh

Josh

Leadwerks Game Engine 5 Beta Updated with Pathfinding, Bone Attachments, and more...

A new update is available for beta testers. This adds navmesh pathfinding, bone attachments, and the beginning of the Lua debugging capabilities.New commands for creating navigation meshes for AI pathfinding are included. NavMesh Pathfinding In Leadwerks Game Engine 5 you can create your own navmeshes and AI agents, with all your own parameters for player height, step height, walkable slope, etc.: shared_ptr<NavMesh> CreateNavMesh(shared_ptr<World> world, const float wi

Josh

Josh

Terrain Deformation

In games we think of terrain as a flat plane subdivided into patches, but did you know the Earth is actually round? Scientists say that as you travel across the surface of the planet, a gradual slope can be detected, eventually wrapping all the way around to form a spherical shape! At small scales we can afford to ignore the curvature of the Earth but as we start simulating bigger and bigger terrains this must be accounted for. This is a big challenge. How do you turn a flat square shape into a

Josh

Josh

Three technology products you should be using in 2021

Note: This article contains some referral links for affiliate systems that I added after writing it. My purpose for including them is so that I can learn how these systems work by participating in them, because I am interested in possibly implementing one of our own in the future. The article was written because these are all things I am using and recommend and I am very bored with the same old things. Except for VR, the last decade of technology has been pretty yawn-inducing. I think Silic

Josh

Josh in Articles

A First Look at the New Editor

I've been wracking my brain trying to decide what I want to show at the upcoming conference, and decided I should get the new editor in a semi-workable state. I started laying out the interface two days ago. To my surprise, the whole process went very fast and I discovered some cool design features along the way. With the freedom and control I have with the new user interface system, I was able to make the side panel extend all the way to the top and bottom of the window client area. This g

Josh

Josh in Articles

Sparse Voxel Octrees

Previously I noted that since Voxel global illumination involves calculation of direct lighting, it would actually be possible to do away with shadow maps altogether, and use voxels for direct and global illumination. This can eliminate the problems of image-based shadows like shadow acne and adjusting the shadow map size. I also believe this method will turn out a lot faster than shadow map rendering, and you know how I like fast performance.  The sparse voxel octree node structure consume

Josh

Josh in Articles

Global Illumination with Voxel Cone Step Tracing

Finally, finally, finally, finally, for the first time since I started working on this feature several years ago, finally we have real-time global illumination with a second light bounce: Below you can see the direct light hitting the floor, bounding up to the ceiling, and then being reflected back down on the floor again. Performance is still good and I have not started fine-tuning optimization yet. I was just trying to get the effect working at all, which was quite difficult to do,

Josh

Josh in Articles

Real-time Global Illumination: Introducing Latency

Since previously determining that voxels alone weren't really capable of displaying artifact-free motion, I have been restructuring the GI system to favor speed with some tolerance for latency. The idea is that global illumination will get updated incrementally in the background over the course of a number of frames, so the impact of the calculation per frame is small. The new GI result is then smoothly interpolated from the old one, over a period of perhaps half a second. Here's a shot of the r

Josh

Josh in Articles

The Day After

I'm taking a short break before I swap GPUs to fix that ATI shader error.   There are now 110 Leadwerks Engine 2.3 users. I did not think the number would be nearly that many.   I am most interested now in documentation, tutorials, and examples as well as improving existing features. With C++, it wasn't worth diving too deep into game tutorials, because only 40% of the programmers would find it useful. Furthermore, it is harder to design useful game components that are easy for users to lear

Josh

Josh

Lua work

I've been revising the Lua design a bit. Ideally this should have been done six months ago, but I did not realize how popular it would be. During beta testing there wasn't much interest in it. That's understandable, because no one likes using beta software. As soon as it was released, suddenly there was some very advanced stuff being implemented immediately. This is great, and I can see my thoughts about how it would benefit us were correct. It also made me want to implement a single-state syste

Josh

Josh

Scenegraph Stuff

Discussing scene graphs in a game development or programming forum can be difficult, because I feel many people are very short-sighted about all the exceptions and complications that can arise in a flexible environment. In fact, there are many situations that will make rendering with a scene graph much slower than without. Many programmers have a tendency to ignore anticipated problems and assume it will work itself out somehow. It's also very hard to predict how bottlenecks will form and what "

Josh

Josh

Merry Christmas!

There's a crazy sale on Steam right now. If you haven't played STALKER yet, you can get it for $10: http://store.steampo...check/app/4500/   In other news...   Framework is being compiled into the engine DLL and being made an official part of the engine API. It will remain a separate piece of code for BlitzMax programmers they can just import. A mechanism will be added to add your own custom post-processing effects, though this will not be available immediately. It will be something like th

Josh

Josh

Design Problem

I finished the collision editor, and now came across a pretty significant design issue. The approach the main editor has always taken is that by the time assets get into it, they are finished and ready for usage. Now I am making it so the model editor can change the structure of a model, save it, and have the main editor reload all instances of it. However, the Lua class scripts cause some problems with this. If I load a model with it's script enabled, the script might delete limbs fromt he

Josh

Josh

×
×
  • Create New...