Reforged UI: An ENB GUI macros file

general download section
Post Reply
  • Author
  • Message
Offline
User avatar
Posts: 99
Joined: 11 May 2014, 10:48

Reforged UI: An ENB GUI macros file

Reforged UI is a macros file I made to make it much easier and quicker to add and edit UI elements for your shaders.
It also provides a seamless easy and quick way to switch between single parameters and various time of day separated parameters which are automatically interpolated, meaning you yourself don't have to do anything to get complex TOD based parameters.
For DX9 ENBs that don't have the TimeOfDay1 and TimeOfDay2 variables there is the option to recreate them using the WeatherAndTime variable, which means you can get the full time of day based functionality even in old ENBs.

For installation, just copy the Reforged folder into your ENB root directory (where your shaders are) and then include "Reforged/ReforgedUI.fxh"


Here's a quick example with code:

Code: Select all

// ...start somewhere AFTER external variables (ENightDayFactor, TimeOfDay1/2 or WeatherAndTime, etc) have been defined

#include "Reforged/ReforgedUI.fxh"

#define UI_CATEGORY Example
UI_SEPARATOR
UI_FLOAT(ExampleFloat, "Example Float", 0.0, 1.0, 0.0)

UI_WHITESPACE(1)

#define UI_PREFIX_MODE PREFIX
UI_FLOAT(ExampleFloat2, "Float w/ Prefix", 0.0, 1.0, 0.0)

UI_WHITESPACE(2)

#define UI_PREFIX_MODE NO_PREFIX
UI_FLOAT_TODI(ExampleFloat3, "Example TOD/I float", 0.0, 1.0, 0.0)
// ^^ ExampleFloat3 can be used as any other variable, the interpolation happens behind the scenes
Image


And here's a screenshot of my bloom's UI made with these macros:
Image


There are a lot of features and I don't feel like covering them all in this post, but here's a list of all the available widget types and split parameter types:
Widgets:
UI_BOOL(variable name, ui name, default value)
UI_INT(variable name, ui name, minimum value, maximum value, default value)
UI_QUALITY(variable name, ui name, minimum value, maximum value, default value)
UI_FLOAT(variable name, ui name, minimum value, maximum value, default value)
UI_FLOAT_FINE(variable name, ui name, minimum value, maximum value, default value, step size)
UI_FLOAT3(variable name, ui name, default red, default green, default blue)
UI_FLOAT4(variable name, ui name, default x, default y, default z, default w)

Split Parameter Types:
SINGLE (it's just the one parameter)
EI (Exterior/Interior)
DNI / DN_I (Day/Night/Interior)
DNE_DNI (Exterior: Day/Night, Interior: Day/Night)
TODI / TOD_I (Dawn/Sunrise/Day/Dusk/Sunset/Night/Interior)
TODE_DNI (Exterior: Dawn/Sunrise/Day/Dusk/Sunset/Night, Interior: Day/Night)
TODE_TODI (Separate Exterior and Interior TOD parameters)
For a full rundown of the features and how to use them, check out the ReforgedUITutorial.fxh file (try including it in a shader and look at the result).
If you include the tutorial file and it errors, it's probably because you're using an older ENB that doesn't have TimeOfDay variables by default, set the 0 in the line "#define DX9_ENB 0" to a 1.

Disclaimer:
Complex interpolators such as TOD based ones do have some performance impact, don't use them needlessly just for the sake of it.
Attachments
Reforged UI.zip
(8.1 KiB) Downloaded 761 times
Last edited by SandvichDISH on 07 Apr 2020, 21:47, edited 1 time in total.
_________________
Reforged ENB for Dragon's Dogma, The Witcher 2, Kingdom Come: Deliverance

Offline
User avatar
Posts: 62
Joined: 11 Mar 2014, 11:07

Re: Reforged UI: An ENB GUI macros file

This is exactly what I was looking for!
The TOD and DNI separations saved me a lot of trouble.

Thanks so much!

Offline
User avatar
Posts: 56
Joined: 02 Aug 2017, 13:30

Re: Reforged UI: An ENB GUI macros file

i think i never said thank you for this :)
i use this a shitton and cant stand enb without anymore. So thank you for this awsome tool :D
Post Reply