GUI Blur Module: UICorners and Padding support

Was looking for a module to help stylize my GUI with foreground blur, but couldn’t find anything that supported UICorners or Padding, made this whole module within a couple of hours and thought that maybe somebody might want to use this for their own experience without having to waste time making one.

Links (Hopefully they work)
The Module on Marketplace

How to use:

Once the module has been required (Preferably from a LocalScript within PlayerScripts) it will instantly initiate.

Adding Blur to a GuiObject:

By using the method :AddBlur(UI: GuiObject, Padding: number) you can instance a BlurObject that will be directly linked to the specified UI with a specified amount of Padding (In pixels).

Automatically adding Blur to a GuiObject or ScreenGui:

By using the method :AddBlurToInstance(Screen: Instance, Padding: number, NamePattern: string, Consistent: boolean): you can instance multiple BlurObjects at the same time into all objects that descend from Screen that contains the NamePattern within their instances name. If the object you are trying to instance into has a GUI that loads and unloads, try setting the Consistent parameter to true so that it will constantly watch for new GUI that gets Parented.

Automatically and Consistantly adding Blur to a ScreenGui (Helpful for ScreenGui that have ResetOnSpawn enabled):

Similar to the method :AddBlurToInstance, the method :AddBlurToScreenGui(ScreenName: string, Padding: number, NamePattern: string, Consistent: boolean) will consistently add BlurObjects to a Specified ScreenName, a reference to a ScreenGui’s consistent name when parented to a player PlayerGui. Consider setting the Consistent parameter to true if your ScreenGui isn’t already loaded before being parented.

Removing Blur from a GuiObject:

By using the method :RemoveBlur(UI: GuiBase) you can completely remove a BlurObject from memory just by setting a reference UI that has been previously instanced.

All BlurObjects are immediately removed upon its reference GUI’s removal

Disclaimers

  • Have not done much testing outside of my current workflow, feel free to reply with any questions or issues you’ve had with this module.
  • Have not tried testing with ScrollingGui’s.
  • GuiObject Rotation has not yet been implemented, nor might never be.

Performance:

Even after linking 256 GUI’s, there didn’t seem to be any noticeable performance drops at all.

With a single BlurObject:

With two hundred and fifty-six BlurObject’s:

I apologize if none of this makes sense it is currently 4 AM and I need to get to sleep, good night.

11 Likes

If any of these is true then you should’ve posted it in the morning in your time, Right now it is afternoon in my time

you forgot to provide how we can actually use it. for ease of access provide us with a script we can use to toggle it on

1 Like
--This is a LocalScript within StarterPlayerScripts

local BlurModule = require(game.ReplicatedFirst.InterfaceBlur) --Make sure to put the module into replicated first

local ScreenName = "ScreenGui" --The name of the ScreenGui's
local BlurName = "Blur" --The name of the GuiObject's you want blurred

BlurModule:AddBlurToScreenGui(ScreenName, 0, BlurName, true)

Nice module!

The only problem I got with is that the blur seems to be a bit offsetted

image
Like you can see on the picture, the bottom of the frame isn’t blurred, and the picture behind is blurred a bit over the blur frame.

Here how I integrated it

The “BlurScript”:

local BlurModule = require(game.ReplicatedFirst.Module.InterfaceBlur)
local UI = script.Parent

BlurModule:AddBlur(UI, 0)

Thank you ^^

If you re-instance the module It should fix the problem, I didn’t realize that the Roblox GUI inset isn’t consistent across all platforms/resolutions. I’m 50% sure this fixed it…

EDIT: Nvm this post, somehow, I rejoined my place this morning, and it’s working!

Thank you for fixing the offset :slight_smile:


ORIGINAL POST :
Unfortunately, it seems completely broken on my side with the new instance.
I tried using :AddBlur and :AddBlurToScreenGui

And I have no errors in the outputs

Btw, is there a way to change the blur intensity?

thank you again ^^