Jump to content
  • entries
    941
  • comments
    5,894
  • views
    866,933

About this blog

Learn about game development technology

Entries in this blog

Building a Collaborative Content Production Pipeline - Part Two

Previously, I described the goals and philosophy that were guiding my design of our implementation of the Leadwerks Workshop on Steam. To review, the goals were: 1. Frictionless sharing of items within the community. 2. Protection of intellectual property rights. 3. Tracking of the chain-of-authorship and support for derivative works.   In this update I will talk more specifically about how our implementation meets these goals.   Our implementation of the Steam Workshop allows Leadwerks

Josh

Josh

Fast Voxel Raytracing with Vulkan

PBR materials look nice, but their reflections are only as good as the reflection data you have. Typically this is done with hand-placed environment probes that take a long time to lay out, and display a lot of visual artifacts. Nvidia's RTX raytracing technology is interesting, but it struggles to run old games on a super-expensive GPU, My goal in Leadwerks 5 is to have automatic reflections and global illumination that doesn't require any manual setup, with fast performance. I'm on the fi

Josh

Josh

Expansion

Jorn Theunissen has been hired on a part-time basis to help design a new set of documentation for Leadwerks. We're taking a top-down approach whereby he designs an outline that encompasses everything you need to know, assuming the reader starts with zero knowledge. The goal is to explain everything in one set of information, down to the level of describing what a mipmap actually is.   The organization of the material will be a linear list of lessons, with no nesting or sub-sections. This ma

Josh

Josh

Vegetation Update

An update is available on the beta branch which adds the new vegetation system. You can open the attached map in the editor to see the system in action. Be sure to create a new project, or update your existing one, in order to get the new shaders and models. vegetationsample.zip   To get this update early you must opt in to the beta branch on Steam.   The new vegetation system is special because it does not use persistent objects stored in memory. Rendering and physics are executed accor

Josh

Josh

Beta update available

An update is available on the beta branch on Steam. This only updates the compiled executables for Lua, only on Windows. Optimization I've rewritten the way lights and objects affect each other. In the old mobile renderer it was necessary to store a list of lights that affect each entity, because it was using a forward renderer and had to send the information for the nearest four lights to the object's shader to calculate lighting. This was a complicated task and is not needed with a defer

Josh

Josh

Justify My Love (of Constructive Solid Geometry Modeling)

One thing I love about constructive solid geometry modeling is that texture mapping is sooooo much simpler than 3ds Max. Most of the time the automatic texture mapping works fine, and when you do need to adjust texture mapping by hand, CSG texture mapping tools are still much easier. The justify buttons line a texture up along a face, or a group of faces.   Although using these tools is fun and easy, programming them is another matter. I dreaded the implementation of the texture justify but

Josh

Josh

Game Launcher and SteamUGC

I'm working to move our Workshop implementation over to the newer SteamUGC API. There were recently some things updated, and that is still being sorted out. I'm also finishing up the game player.   The first incarnation of Leadwerks Game Launcher was pretty utilitarian (and ugly):   I realized this was pretty drab for a product aimed at consumers, so I designed a more outlandish colorful interface that was purely web-based:   This one looks nice, but you can tell it will start to fee

Josh

Josh

Multiplatform Madness

So after a lot of learning and mistakes, I finally have Leadwerks Engine 3 running on OSX Snow Leapord, Lion, and iOS. Rather than write out a detailed blog, I'll just throw a lot of random thoughts your way:   -OpenGLES2 is a nice blend of OpenGL 2 and OpenGL 3.3. I'm really surprised my OpenGL 3 shaders translate easily into OpenGLES2 shader code, with only a few changes. In fact, the iOS renderer looks exactly like the deferred OpenGL 3 renderer, except for shadows and some post-effects.

Josh

Josh

Single-file SPIR-V shaders for Vulkan

It is now possible to compile shaders into a single self-contained file that can loaded by any Vulkan program, but it's not obvious how this is done. After poking around for a while I found all the pieces I needed to put this together. Compiling First, you need to compile each shader stage from a source code file into a precompiled SPIR-V file. There are several tools available to do this, but I prefer GLSlangValidator because it supports the Google #include extension. Put your vertex

Josh

Josh

Tech Update: OpenGL 4 Deferred Renderer

The OpenGL 4 renderer for Leadwerks 3.1 is well underway. I began implementing deferred lighting in earnest last Friday. Previous work included setting up MSAA on deferred buffers, as well as implementation of the Leadwerks Buffer class, which functions as a thin wrapper around OpenGL FBOs (frame buffer objects). The engine already tracks relationships between objects and lights, and this system was able to be used to provide a list of shadow-casting objects for each point and spot light.  

Josh

Josh

Preparing Leadwerks for the Future

In this blog I am going to explain my overarching plan to bring Leadwerks into the future and build our community. First, regarding technology, I believe VR is the future. VR right now is basically where mobile was in 2006. The big publishers won't touch it and indies have a small but enthusiastic market they can target without fear of competition from EA. I have an HTC Vive and it is AWESOME! After using it, I don't really want to play games on a 2D monitor anymore. I want to be in the gam

Josh

Josh

Double-buffered shadow maps

I got my idea working with spot lights! You can simply use a shadow mode of 2 to indicate an object or light should be considered "static". A light that has the static mode set will use two shadow maps; one for static objects and one for dynamic objects. In the image below, the walls and room are static, and the oildrum has the regular dynamic shadow mode set. As you can see, redrawing the shadow only requires 650 triangles. Without this feature, the whole room and everything in it would ha

Josh

Josh

Voxel Cone Tracing

I've begun working on an implementation of voxel cone tracing for global illumination. This technique could potentially offer a way to perfrorm real-time indirect lighting on the entire scene, as well as real-time reflections that don't depend on having the reflected surface onscreen, as screen-space reflection does. I plan to perform the GI calculations all on a background CPU thread, compress the resulting textures using DXTC, and upload them to the GPU as they are completed. This means t

Josh

Josh

GMF2, Plugins, and Modding

I wanted to get a working example of the plugin system together. One thing led to another, and...well, this is going to be a very different blog. GMF2 The first thing I had to do is figure out a way for plugins to communicate with the main program. I considered using a structure they both share in memory, but those always inevitably get out of sync when either the structure changes or there is a small difference between the compilers used for the program and DLL. This scared me so I we

Josh

Josh

ZombieTime

AI is always a fun programming topic, and it's even more fun when you're mixing a physics-based character controller with dynamic navmesh pathfinding.   We planned on using navmesh pathfinding from the very start of the design of the new engine. Because it was integrated from the very beginning our implementation works really nicely. Pathfinding is completely automatic and dynamic. There are no commands you need to call to make it work. When part of the scene changes, the navigation data f

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

Variance Shadow Maps

After a couple days of work I got point light shadows working in the new clustered forward renderer. This time around I wanted to see if I could get a more natural look for shadow edges, as well as reduve or eliminate shadow acne. Shadow acne is an effect that occurs when the resolution of the shadow map is too low, and incorrect depth comparisons start being made with the lit pixels: By default, any shadow mapping alogirthm will look like this, because not every pixel onscreen has an exact matc

Josh

Josh

How to make a prefab

Step 1. Build the object you want to make into a prefab. Here I have staircase I want to make into a reusable object.   Step 2. Drag all the objects onto one, to make it a parent of the others. Prefabs need one top-level entity.   Step 3. Click on the top-most object in the hierarchy and select the "Save as Prefab" menu item. You'll get a file save dialog so you can choose the file to save.   Step 4. Begin using your prefab by dragging it into the scene from the asset browser

Josh

Josh

Apple and Leadwerks

I was thinking this morning how Apple has influenced my life and the company Leadwerks. You might ask why I am talking about this, since we are only now coming out with our first product for any Apple operating system. Well, before Windows existed, back in the 1980's, this was my first computer:     The first "game" I ever made was in Macintosh Paint. I drew a road from a top-down view, with barriers randomly placed on either side. I drew a race car, zoomed in the image, and used the se

Josh

Josh

Scripted Behavior

The stock scripts that come with Leadwerks form a continually expanding game framework that can be used in many different ways. The reuse we get out of the door, switch, trigger, and AI scripts is really great. Every time I add a new script I can count on it being used in many different ways.   Sometimes this requires a custom model in order to develop and demonstrate usage of the script. It's best for me to have one model made exactly to my specs, and then make everything else conform to t

Josh

Josh

Leadwerks 5 beta update adds Visual Studio Code Integration for Lua

A new update is available to beta testers. This makes some pretty big changes so I wanted to release this before doing any additional work on the post-processing effects system. Terrain Fixed Terrain system is working again, with an example for Lua and C++. New Configuration Options New settings have been added in the "Config/settings.json" file: "MultipassCubemap": false, "MaxTextures": 512, "MaxCubemaps": 16, "MaxShadowmaps": 64, "MaxIntegerTextures": 32, "MaxUIntegerTe

Josh

Josh

Peer-to-peer Networking and the Floating Server

I have Steam peer-to-peer networking commands implemented into Leadwerks 4.6. Here are the commands. Note this complex system has been boiled down to just three simple commands: class P2P { public: #ifdef LEADWERKS_5 static bool Send(uint64 steamid, const int messageid, shared_ptr<BankStream> data, const int channel = 0, const int flags = 0); static bool Send(uint64 steamid, const int messageid, shared_ptr<Bank> data, const int channel = 0, const int flags = 0); static shared_

Josh

Josh

Development

I've been working on water. It's a challenge to get it to work properly with the post-effects stack and lighting, something I never did quite right in Leadwerks 2. However, the results are turning into the best implementation of water I've ever made. Water blends naturally with post-effects stack. Water reflection/refraction equation and behavior is improved over Leadwerks 2. Water ripples don't have an obvious direction of flow and look very realistic, without looking "wrong" when pla

Josh

Josh

Visual Studio 2017 Support

The beta branch of the professional version is upgraded to use Visual Studio 2017. You can download the release candidate for free here: https://www.visualstudio.com/vs/visual-studio-2017-rc/   Your existing projects should work with VS 2017 with no changes, but you might want to hold off while we test if you are in the middle of a project. New projects you create should open with VS 2017 by default.  

Josh

Josh

×
×
  • Create New...