Jump to content

upgRadiant


Recommended Posts

So my big project for now is to make mapping tutorial videos...and GTKRadiant is such a bugfest that I want nothing to do with it, both 1.5 and 1.6. That said - the internals of Radiant are actually rock solid, but because of the bugs nobody seems to care much.

So - Radiant 1.6.6 has been forked, and a new branch is being worked on, currently referred to as DogiRadiant. I don't have anything visual to show for it yet, other than a screenshot of the modified color scheme on the grid, but here it is anyway:

spacer.png

 

Things that have been removed:

  • The preferences menu has been almost completely gutted. Most of the nonsense features have been removed. There are so many things in there that were relevant to 1999, when computers had 64 MB of RAM. It's 2020, and it's time for it all to go. (The code for these features mostly remains, but they have been removed from the menu)
  • The Z-Window, on the far left side, has been completely removed. It was useful in the days of DOOM and Quake 1, but not any more.

 

New features that have been added:

  • The grid can zoom in much farther, and also zoom out a little bit farther as well.
  • The grid can now go up to 4096 in size, and down to 0.125. (It can actually go down to 0.03125, but due to float point inaccuracy it has been capped at 0.125...for now.)
  • Cubic clipping increments have been increased from 64 to 1024, and the maximum cubic clipping distance is attached to the maximum render distance
  • Maximum render distance has been drastically increased to 65536 (Half of the entire grid) - Cubic clipping can now be used if Radiant is running too slow
  • Texture window scaling has new pixel-size options - normally, textures can only be scaled at 10%, 25%, 50%, 100% and 200%. New options are 64 pixels, 128 pixels, 192 pixels, 256 pixels, 384 pixels, and 512 pixels. (This was previously an option hidden in the preferences, but it makes so much more sense in the menu, and is easier to use with predefined options)
  • The 3D camera movement was removed from the preferences menu, and has instead been attached to the grid size. So if you are doing a detailed edit on a small object, it will be very easy to get close to it. If you are trying to move quickly across a large map, set the grid size up high and you'll be there in no time.
  • The 3D camera view's strafing feature has been modified to not lock the Y axis to a vertical position. If you want to lock the Y axis vertically, press Ctrl + Shift to strafe instead.

 

Bugs that have been fixed:

  • Grid has been recolored so it's much easier to work at both higher and lower settings
  • Edits below grid size 0.5 are no longer lost
  • Dragging something off the edge of the grid will no longer shoot you off into the distance without warning - scroll speed has been massively nerfed
  • Surface inspector no longer performs an "Undo" when closed
  • Surface inspector now updates its numeric values when changes are made to selected materials
  • Large undo/redo operations are now much faster
  • Undo operations can no longer get out of sync - Radiant makes you wait until one operation is done before performing another
  • Increased the undo limit from 64 to 512, and changed the maximum undo memory buffer size from 2 MB to 2 MB x the undo limit (So maximum 1 GB, more if the undo limit is increased)
  • Right-clicking to scroll in the texture window will now stop at the bottom of the window like it's supposed to, instead of scrolling off into nothingness
  • Making an arbitrary sided sphere or cone brush will no longer crash Radiant, and failure to create them will print a message to the console telling you why it failed

 

Planned features if I can stick with it long enough:

  • Windows compatibility (Right now I'm doing this on Linux, so it will require effort to get it on Windows)
  • Add a preference to the preferences menu for the cubic clipping distance
  • Reorganize the toolbars in a more useful way
  • Make GTKGenSurf more user friendly
  • Fix up vertex editing (This will probably be very hard)
  • Making EVERY edit trigger an undo point (Since the buffer is 512, may as well fill it up)
  • Convert the internals to use doubles instead of floats, and enable the grid precision all the way down to 0.03125 units - this would be excellent for modeling at small sizes
  • If the internal math is successfully converted to doubles, increase the grid size
  • New save format, JSON based
  • "Smart objects" - similar to a smart object in Photoshop, I want to be able to save a group of brushes as a prefab, and then copy/paste it into the map at will, and deform/warp them individually as desired

 

Already the program feels a lot more professional than before - but there's still a very long ways to go. I wouldn't expect to be done with this for a year or so, since I'm new to C and haven't even touched C++ yet.

Comments are welcome! Report any bugs you know of, and I'll check them out - I can't promise everything will be fixed, but at least I can look! Also, if another version of Radiant does something better, let me know - all Radiant clones are open source, so it's all up for grabs!

Link to comment
3 hours ago, NAB622 said:

Does anyone have any objections to this being renamed to "UpgRadiant" ? I need to change the name, and that describes what it is pretty well, but I'm terrible with names.

Noone likely minds the name, just appreciate the effort!

Link to comment

Update for the last few days of work (I'm under quarantine for the next few days so I'm getting a lot done):

  • The camera is now bound to the grid. There is a small "Cushion" distance outside the grid boundaries where it will be allowed to go, but it will stop there. No more getting lost out in the void.
  • The grid view cannot leave the grid. Again, no more getting lost.
  • Brushes cannot be rotated/scaled/created/resized outside the grid. As soon as the grid boundary is reached, Radiant will cancel the operation and give a message in the console. Because of how I did it, this does mean larger operations will be a bit slower - but with how fast today's computers are, I doubt it'll be noticeable. (Still working on stopping the user from moving existing brushes off the grid, though.)
  • Surface inspector will provide live updates for textures being drag-edited in the 3D view.
  • Surface inspector will now "Roll over" the shift and rotate numbers when it reaches the maximum - so if you have a rotate value of -15 on a texture, Radiant will change it to 345. Same thing with hShift and vShift - if they exceed the texture resolution, they will snap back to where they should be. This takes place seamlessly in the background and should not be noticed by the user, and makes texture editing much easier.
  • The fit option in the surface inspector can now fit up to 512x512 (Instead of 32x32....I've had scenarios where 32 wasn't enough). This also works with the aforementioned rolling over of hShift and vShift numbers as well, resulting in easy numbers to manipulate.

I still have a long ways to go, and there's a significant list of bugs I've created along the way.....but so far these are far less serious than the ones being fixed.

Lancelot likes this
Link to comment

I just spent some time redesigning the surface inspector. Here's what I came up with. Anyone have any thoughts? It still has all the functions the old one did, plus some extras for ease of editing and to help newbies understand.

(Keep in mind that the dark window color is from my GTK theme on Linux, and on Windows it will probably be the usual light gray)

new_surface_inspector.png

 

Is this easy enough to understand? Is it too cluttery? Is it missing something important? Is it perfect?

z3filus, OCD2, Aldro Koon and 1 other like this
Link to comment

netRadiant custom will likely be far more advanced than this when it is complete - all I am trying to to is bugfix the program so it stops crashing as much, and simplify/streamline the interface where needed. Once I make the tutorial videos, I intend to leave it be, except for the occasional bug fixes. I'm just trying to keep this as close to the original release as possible while making it actually usable, even for games other than JA. That said - while digging through the source, I've discovered old features that fell by the wayside, that will make mapping so much easier - they just needed a re-tuning.

Edited by NAB622
speling
OCD2 and Psyk0Sith like this
Link to comment

Before I get too much farther, I have to ask - does anyone here have experience with compiling GTKRadiant for Windows? It looks like it's going to be a nightmare, and any help would be welcome. The instructions guide is less than helpful, and I'm still totally new to all this.

Progress is getting a bit slower - I'm fixing a lot of superfluous bugs and bugs that are under the hood, plus I'm running into much harder stuff that I'm needing to seek help for. I did make a few more modifications to the surface inspector - and now, it can accept 2 decimal places when fitting a texture, as well as negative values, making the effective range -512.00 to 512.00. Hopefully the changes aren't confusing - let me know what you think!

new_surface_inspector_2.png

 

Next up on the list: the patch inspector is getting addressed.

OCD2 likes this
Link to comment
  • 1 month later...
  • 2 weeks later...

Update!

Nothing visual to show for this one either, since it's all internal - but the internal vector math in Radiant has been converted from float precision to double precision. What this means is:

  • The lowest precision on the grid will indeed be 0.03125, not 0.125
  • You can edit at 0.03125 all the way to the edge of the grid, and your edits will not flake out
  • You are guaranteed the 6-decimal precision of a .map file all the way to the edge of the grid (No float point errors)
  • The grid can theoretically increase in size (This is a bad idea since JA still runs on float precision, but it CAN be done)
  • q3map2 should not need the T-Junction phase any longer, which is good because it creates a bunch of pointless geometry everywhere

Now, because of this, I still have several serious things to fix:

  • q3map2 is completely broken (It's still running on float precision internally, and I will have to have it convert everything down to float when it saves the BSP file)
  • The grid view in Radiant needs a few heavy changes to the way it renders - if you zoom in to 0.03125 and go halfway to the edge of the grid, everything gets janky and unusable, and it gets worse the further you go toward the edge
  • Radiant is somewhat less stable, since there are still things trying to run on float precision in various places. I have to hunt them all down

Finally:

  • The camera window will also likely flake out a little (Below 0.5 precision) at the edge of the grid, since OpenGL runs on float precision. I do not intend to even try to fix this, as it will reflect what will happen in JA, since JA also uses float precision.

Hopefully I will have screenshots of a few new things soon, but since this is all internal stuff, there's nothing to show yet. However, once the internals are set, the benefits will manifest in the other features!

Psyk0Sith, ooeJack, Lancelot and 1 other like this
Link to comment

Small update! Got two more things added, although I had to have some help.

  1. When a map is loaded, Radiant will now snap the camera to the location of an info_player_intermission first (If there is one). Info_player_start and info_player_deathmatch are still used, but they are fallbacks. Radiant will also take on the same directional angles (Including those of a target!) of whatever entity it snaps to. This means that Radiant will see the same thing as the game when the map is loaded.
  2. When selected items are hidden behind other geometry, the selection outline will show as a dotted line, just like Radiant 1.5 does.

Here is a shot from ffa5_sample, just after loading (To show the camera angle), and with a few items selected to show the dotted lines:

upgRadiant%20Stippling.png

OCD2 and ooeJack like this
Link to comment

This is a relatively small update, related to the one above. I've made lots of small changes, but some of them required figuring out some vector math (Yikes)...and it's impossible to show what's happening with still images, so here's a video of what's new:

 

The new stuff is:

  1. The camera icon on the grid has been made bolder so it is easier to see, and the FOV indicators on it will change length based on the camera's angle relative to the current grid axis.
  2. Moving and angling the camera on the grid (Ctrl + Middle click to move, middle click to set angle) is much improved as well, although most of the changes there are likely not noticeable. Bottom line, the camera will correctly "Roll over" to the other side, instead of turning upside-down and/or reversing the input like I've seen it do in the past. (Not sure what version of Radiant that was???)
  3. Finally, the angle arrows on entities will show the correct orientation when targeted at an entity, or when using the "angles" key, and will update every frame, so they will always point in the right direction.

I forgot to show the dotted line selections, but you can sort of see it in a few places.

Also worthy of note, Bobztoolz is completely broken and doesn't even show up on the plugins toolbar. I will have to fix that soon.

ooeJack, DarthValeria and Stoiss like this
Link to comment

Small update. As usual, not much to show, but here's the goods:

  1. Vertex and edge flags are now a LOT larger. Since you can zoom in much further than before, this will make vertex and edge selecting and editing much easier. The size was also added to the preferences, so it is easy to change if you don't like it.
  2. The camera icon on the grid now has a thin black outline to guarantee visibility.
  3. In the previous update, I had made the FOV lines for the camera icon (On the grid) change in length based on the camera’s angle relative to the current grid view - now, the aperture angle of the FOV lines will change to match the current camera FOV (Based on the window size). The camera icon will now tell you exactly what it is looking at on the grid.
  4. Fixed a bug where the grid and camera would not re-render correctly when windows were resized.
  5. Rewrote the way the grid zoom is calculated. It is much cleaner now (No visible change with this one).
  6. The undo buffer is now cleared when a map is loaded or a new map file is started. (No idea why this wasn't a thing to begin with).

Here's a few shots of the improved FOV indicator, as well as the new vertex flag size:

Spoiler

CameraFOV1.png

Spoiler

CameraFOV2.png

I know progress has been slow, and I apologize for that, but I'm still working a lot of hours, and that's my main inhibitor - the second inhibitor being that I'm having to learn some basic vector math as well as C, and I am very bad at math.

ooeJack and OCD2 like this
Link to comment

Another update! Here's what's new:

  1. The plugins are all fixed and working again, Bobztoolz in particular.
  2. The camera view now has a horizontal FOV setting (As of right now, this WILL adversely affect frame rate if it is over 90 degrees since I couldn't figure out the culling code, but the new cubic clipping settings should help with that). Had to get some help on this one, but it's absolutely worth it.
  3. The grid and camera had bugs where they would not re-render when the windows were resized. This has been fixed.
  4. EDIT: The dialog boxes have had mnemonics added. Instead of having to click "Yes" "No" or "Okay" all the time, you can now use the keyboard (Alt + mnemonic key). Small change, but great for power users.
  5. The patch inspector is almost done! I have attached an image below, let me know what you think (I'm very interested in input):

upgRadiant%20Patch%20Inspector.png

I do also intend to do some major overhauls on prtview and gtkgensurf, but that's stuff for later. Both of them are full of useless, bogus settings that don't need to be there. Prtview can actually be reduced to just a toggle button, so that'll be my goal when I get to it.

Lancelot, OCD2, Spaghetti and 1 other like this
Link to comment

Aw, thanks. I have no doubt this will take at least 6 more months to complete, maybe even closer to 10... But when it's done it'll make things so much easier, at least for me. I still plan to do those tutorial videos, too, but I can't even start them until radiant is done anyway.

Ultimately, Radiant should just be replaced with a whole new program, but I don't have the skills or the time to start from scratch. Plus, as I say all the time, Radiant's internals really are rock solid, they just need the bugs fixed, and a UI to match.

Aldro Koon and OCD2 like this
Link to comment

Right now this is native to Linux. I'd love to get it on Windows but I'm not very skilled, so I'll revert back to the old Scons build system for that, cross my fingers and hope it works. If it doesn't, I will still try my best to get it on windows.... But like I said, not much skill here.

Right now that's not even close, though. I'm going to be looking into the possibility of migrating to GTK3 once enough of the bugs are fixed. GTK2 only supports three mouse buttons, and I'd like to use buttons 4 & 5 to change the current grid size, since I attached everything to it. We'll see what happens...

Link to comment

Another update! Big progress today.

  1. The horizontal culling code in the renderer has been corrected! FOV settings above 90 will no longer bog down the renderer.
  2. Vertical culling code has been added to the renderer! This means that all four sides of the camera will cull out brushes that are not visible (Previously this was restricted to just the left and right). This should greatly increase performance on large maps, especially when the render distance is set up high (The old render distance was 20000, and I have it set to 65536 by default now).
  3. Misc_model_static will now show up just like a misc_model, instead of a pointless red block.
  4. The preferences have been updated to reflect all the new camera settings. I have an image and a video of the changes below:
Spoiler

upgRadiant%20Camera%20Preferences.png

 

(The video is actually high quality this time because I fixed the bad recording settings in OBS.....whoops)

Thoughts are welcome!

ooeJack and OCD2 like this
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...