# BLUI Open Source HTML5/JS/CSS HUD/UI

**URL:** <https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338>\
**Category:** Game Development\
**Tags:** unreal-engine\
**Created:** [February 4, 2015, 11:49pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338 "2015-02-04T23:49:29Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 4, 2015, 11:49pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/1 "2015-02-04T23:49:29Z")

</div>

Greetings!

Current Release: [https://img.shields.io/github/release//BLUI.svg?style=flat-square](http://bit.ly/BLUIRelease1)

Check GitHub release page for changelog

You may have seen my post about my Chromium Embedded Framework powered UI engine. But it’s made so many strides recently that I’ve decided it needs a new thread.  
First off, it’s completely redone!

Here’s a few demos:

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/4/6/3462c5eeb479932751be51dfdc2307fc614db95d.jpeg "BLUI - Open Source HTML driven UIs for UE4") ](https://www.youtube.com/watch?v=Msc67HLCj5Y)

and

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/7/3/7736512c620ff47fdad2549676265fce4ec5c02d.jpeg "BLUI - Creating a web view") ](https://www.youtube.com/watch?v=VCPhsxd5rTE)

![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/c/f/acf54d79589cc86b49f7e21e9c12b1677c53c140.gif)

[Grab it here!](http://bit.ly/BLUIRelease1)

[Quick Start Wiki](https://github.com//BLUI/wiki/Simple-Setup-(Windows-64-Bit))

[JavaScript Events Wiki](https://github.com//BLUI/wiki/JavaScript-Events)

Demo Project (currently needs to be updated to 3.0, hang tight!)

Do you use BLUI in your project? I’d really love it if you credit me and it! You can even use the [logo right here](https://res.cloudinary.com//image/upload/v1423576170/BLUI-Transparent_eu582n.png)!

As you can see, we’re using plain old HTML loaded from disk, rendered to a texture, then painted on an image widget using a UMG brush!

I’m trying to make the blueprint system as simple as possible, there aren’t any dependencies on specific display methods, allowing you to instantiate a “BluEye” within ANY blueprint, set the options using blueprints, then grab the material instance using a node that you can paint on ANYTHING you like. There are also helper nodes and functions to pass mouse input, and keyboard input into the “browser.”

Once again. It’s free, MIT licensed, and is powered by CEF.

GitHub Link: [https://github.com//BLUI](http://bit.ly/BLUI-Github)

Here’s a quick technical run down on how it works!

- The plugin spawns off a CEF process in the background
- This process is like the Chrome browser, it will take care of loading the page, js, css etc.
- The plugin sips off the render buffer of CEF
- Translates that into a texture
- And forwards any input to the browser
- That’s it!

There is minimal impact on performance as all the HTML page loading happens in another process. The texture also only updates when Chromium requests a redraw, it does not redraw every tick!

This is open source! If you find bugs, hit me up or file an issue on the Github page! Better yet, fix it yourself if you’re up to the challenge and make a pull request!

Please make pull requests, leave feedback, and let me know what you think! I hope this makes your lives easier while developing with the UE engine!

BLUI got featured on the community spotlight!

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/2/4/7248bbd3b253f40cbcd3fa65e86bf0ca6fcd87a8.jpeg "Announcing Unreal Dev Grants | News | Unreal Engine") ](https://www.youtube.com/watch?v=WDdesD_5Xm0)

At time marker 45:15

BLUI Got a Dev Grant!

[Check out the batch of grants here!](https://www.unrealengine.com/blog/epic-games-awards-71k-in-unreal-dev-grants)

This is an honor! I never expected any of my projects to advance this far! I only have you guys to thank so…

Thanks guys!

- Shea

---

<div class="post-metadata">

**Author:** ![JayKavanagh](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JayKavanagh](https://forums.unrealengine.com/u/JayKavanagh)\
**Post date:** [February 5, 2015, 1:03am UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/2 "2015-02-05T01:03:40Z")

</div>

looking sweet. Seems just like [radiantsdk.com](http://radiantsdk.com) which is good cause I can’t make that work and my game really needs something like this…development is so much more important but will there be an how to videos any time soon to walk us through it.

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 5, 2015, 1:14am UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/3 "2015-02-05T01:14:34Z")

</div>

[QUOTE=bronergames;216422]  
looking sweet. Seems just like [radiantsdk.com](http://radiantsdk.com) which is good cause I can’t make that work and my game really needs something like this…development is so much more important but will there be an how to videos any time soon to walk us through it.

I will be creating a video! Hopefully tomorrow!

---

<div class="post-metadata">

**Author:** ![JayKavanagh](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JayKavanagh](https://forums.unrealengine.com/u/JayKavanagh)\
**Post date:** [February 5, 2015, 1:28am UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/4 "2015-02-05T01:28:10Z")

</div>

Sounds good, Ill def be one of the first to try it out, nice work

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 6, 2015, 3:01pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/5 "2015-02-06T15:01:18Z")

</div>

Thanks for the feedback!

[Quick Start Wiki!](https://github.com//BLUI/wiki/Simple-Setup-(Windows-64-Bit))

Should give some more information on how to get going!

---

<div class="post-metadata">

**Author:** ![BrUnO\_XaVIeR](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bruno_xavier/32/1110230_2.png) [@BrUnO\_XaVIeR](https://forums.unrealengine.com/u/BrUnO_XaVIeR)\
**Post date:** [February 9, 2015, 9:04pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/6 "2015-02-09T21:04:30Z")

</div>

This looks interesting!

[QUOTE]  
Copy all contents of shipping into your packaged game’s GameName/Binaries/Win64, these are the required files for the Chromium process.

But what about Win32??  
Can I add a “web browser” which opens youtube in game for example? How are keyboard/mouse inputs handled?

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 9, 2015, 10:08pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/7 "2015-02-09T22:08:44Z")

</div>

[QUOTE=BrUnO XaVIeR;219088]  
This looks interesting!

But what about Win32??  
Can I add a “web browser” which opens youtube in game for example? How are keyboard/mouse inputs handled?

The CEF Build used with BLUI is only Windows 64 bit, with some work you could replace these libraries with the 32 bit version from the CEF Builds site.

As far as input goes, take a look at the Example HUD blueprint in the Release zip file, there are blueprint nodes in the BluEye class for help with input

---

<div class="post-metadata">

**Author:** ![BrUnO\_XaVIeR](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bruno_xavier/32/1110230_2.png) [@BrUnO\_XaVIeR](https://forums.unrealengine.com/u/BrUnO_XaVIeR)\
**Post date:** [February 10, 2015, 6:05pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/8 "2015-02-10T18:05:43Z")

</div>

I mean, how to handle input on a plane like I were navigating in Chrome, not HUD controls.  
Show mouse cursor on the plane, make it receive keyboard input, etc.

I’ve tested it and looks pretty great and simple install. The simpler one I’ve seen so far; But it’s early in development, right.  
There’s no way to shutdown a instance, it is still running until I close UE4 Editor.  
Even when I stop playing the game it is still running.

I mean, if I set it to disabled, rendering will stop; But try doing that on a page of a video online. The video is still running on the background even if the rendering of the plane in-game has stopped.  
Also, the rendering is always on square texture?!

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 10, 2015, 7:08pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/9 "2015-02-10T19:08:15Z")

</div>

[QUOTE=BrUnO XaVIeR;219635]  
I mean, how to handle input on a plane like I were navigating in Chrome, not HUD controls.  
Show mouse cursor on the plane, make it receive keyboard input, etc.

I’ve tested it and looks pretty great and simple install. The simpler one I’ve seen so far; But it’s early in development, right.  
There’s no way to shutdown a instance, it is still running until I close UE4 Editor.  
Even when I stop playing the game it is still running.

I mean, if I set it to disabled, rendering will stop; But try doing that on a page of a video online. The video is still running on the background even if the rendering of the plane in-game has stopped.  
Also, the rendering is always on square texture?!

Hello again, BLUI tries to not be in the way at all and only provide the functions necessary to create your own custom solutions. It does not assume anything about the project.  
That being said, BluEye instances shut down their browsers when they are destroyed by the engine. The processes you see (should be about two) while the editor is idle are simply something CEF3 must do. They also provide the remote page inspection tools page on port 7777.

If you want to stop a video, use something like the youtube player API and execute javascript to pause the video when you pause rendering. Destroying a BluEye is like closing the tab in chrome, it will lose all state.  
But if you want to close the browser by force I’ll be adding a method for this in the next 1.2 release.

For keyboard input, I would recommend overriding the viewport class in C++ and intercepting the key input events from there. For mouse input, without a UMG widget in 3D space you need to take care of calculating mouse input yourself. On a plane, it won’t be to hard, just fire a trace and figure out where it hits, translate that to X,Y coords and run the mouse click method.

I’m not sure what you mean by

[QUOTE]

Also, the rendering is always on square texture?!

It’s a simple texture created from the buffer from CEF’s paint event

It is very early in development, so please keep this in mind, hope this answered your questions.

---

<div class="post-metadata">

**Author:** ![BrUnO\_XaVIeR](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bruno_xavier/32/1110230_2.png) [@BrUnO\_XaVIeR](https://forums.unrealengine.com/u/BrUnO_XaVIeR)\
**Post date:** [February 10, 2015, 7:16pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/10 "2015-02-10T19:16:48Z")

</div>

Thank you for the reply. the thing with ‘square texture’ is, I’m trying to have the page rendering on a 19:6 quad but the output image is always a “browser window” of around 512x512 with scrollbars on it.  
I guess is the default “window size” ?! If you could point to me where in the source I can change that to go on and keep experimenting with the plugin would be great.

Edit: nevermind. Found it 🙂

I’ve added a blueprint to destroy the “tab” process because I want it to stop running when Player leaves by overlapping a trigger box.  
Now I will take a look at input routines… But hope a ‘force destroy’ function is added when you update as well. Thank you, this plugin is great 🙂

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 10, 2015, 8:25pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/11 "2015-02-10T20:25:03Z")

</div>

[QUOTE=BrUnO XaVIeR;219682]  
Thank you for the reply. the thing with ‘square texture’ is, I’m trying to have the page rendering on a 19:6 quad but the output image is always a “browser window” of around 512x512 with scrollbars on it.  
I guess is the default “window size” ?! If you could point to me where in the source I can change that to go on and keep experimenting with the plugin would be great.

Edit: nevermind. Found it 🙂

I’ve added a blueprint to destroy the “tab” process because I want it to stop running when Player leaves by overlapping a trigger box.  
Now I will take a look at input routines… But hope a ‘force destroy’ function is added when you update as well. Thank you, this plugin is great 🙂

Yup, just change the size values (Width and Height) before calling init() (you can also set these in blueprints) on the BluEye instance. Thanks for the feedback, I’ll be making a force destroy method in 1.2

---

<div class="post-metadata">

**Author:** ![Lightnet](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Lightnet](https://forums.unrealengine.com/u/Lightnet)\
**Post date:** [February 11, 2015, 6:13pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/12 "2015-02-11T18:13:51Z")

</div>

Can’t seem to get it work that I am seeing a gray ui. Could make project file. Using the plugin.

---

<div class="post-metadata">

**Author:** ![BrUnO\_XaVIeR](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bruno_xavier/32/1110230_2.png) [@BrUnO\_XaVIeR](https://forums.unrealengine.com/u/BrUnO_XaVIeR)\
**Post date:** [February 11, 2015, 6:27pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/13 "2015-02-11T18:27:21Z")

</div>

@Lightnet You have to set for current Level in your ‘World Settings’ your custom GameMode which ticks the BluManagerLoop()…

The Tick override would be something like this:

```auto

void A **PROJECTNAME** GameMode::Tick(float DeltaSeconds){
	Super::Tick(DeltaSeconds);
	BluManager::doBluMessageLoop();
}

```

---

<div class="post-metadata">

**Author:** ![Lightnet](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Lightnet](https://forums.unrealengine.com/u/Lightnet)\
**Post date:** [February 11, 2015, 11:06pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/14 "2015-02-11T23:06:42Z")

</div>

I did that and nothing happen. I am using the UE 4.6.1 version.

* * *

Never mind there was just a bug for some reason it didn’t run right. Had to make a new project.

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 12, 2015, 1:55pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/15 "2015-02-12T13:55:43Z")

</div>

[QUOTE=Lightnet;220487]  
I did that and nothing happen. I am using the UE 4.6.1 version.

* * *

Never mind there was just a bug for some reason it didn’t run right. Had to make a new project.

Glad you could resolve it

---

<div class="post-metadata">

**Author:** ![JayKavanagh](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JayKavanagh](https://forums.unrealengine.com/u/JayKavanagh)\
**Post date:** [February 12, 2015, 2:44pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/16 "2015-02-12T14:44:13Z")

</div>

Hey , just for my only early education. Does your plugin support adding a camera view? I want to be able to build a lil hud that can slide open and show a in game security camera.

---

<div class="post-metadata">

**Author:** ![BrUnO\_XaVIeR](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bruno_xavier/32/1110230_2.png) [@BrUnO\_XaVIeR](https://forums.unrealengine.com/u/BrUnO_XaVIeR)\
**Post date:** [February 12, 2015, 3:28pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/17 "2015-02-12T15:28:45Z")

</div>

blu\_ue4\_process instances are supposed to get killed when we hit the “Stop” button in editor, but the only fade away is if we close UE4 Editor itself. Any ideas on how to fix that? I don’t know if UE4 fires an event whe finishing Play mode that Blui could hookup the BeginDestroy() function.  
At current state it causes sever memory leaks in Editor, if you hit Play/Stop many times a lot of parentless processes and textures will be left in memory with no use for them.

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 12, 2015, 3:59pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/18 "2015-02-12T15:59:21Z")

</div>

[QUOTE=BrUnO XaVIeR;220867]  
blu\_ue4\_process instances are supposed to get killed when we hit the “Stop” button in editor, but the only fade away is if we close UE4 Editor itself. Any ideas on how to fix that? I don’t know if UE4 fires an event whe finishing Play mode that Blui could hookup the BeginDestroy() function.  
At current state it causes sever memory leaks in Editor, if you hit Play/Stop many times a lot of parentless processes and textures will be left in memory with no use for them.

Hello again, I am not getting this behavior on my end, this might be because the UMG widget in my test project does fire the begindestory method, I can see the blu\_ue4\_process close as soon as I hit “Stop” in editor. It shouldn’t be too difficult to add a method to close the browser yourself:

```auto

void UBluEye::CloseBrowser()
{

	if (browser)
	{
		browser->GetHost()->CloseBrowser(false);
	}

	DestroyTexture();

}

```

EDIT: I’ll be adding this method in the next update

---

<div class="post-metadata">

**Author:** ![AaronShea](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AaronShea](https://forums.unrealengine.com/u/AaronShea)\
**Post date:** [February 12, 2015, 4:01pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/19 "2015-02-12T16:01:15Z")

</div>

[QUOTE=bronergames;220833]  
Hey , just for my only early education. Does your plugin support adding a camera view? I want to be able to build a lil hud that can slide open and show a in game security camera.

Hello, current it does not support this. However, it would be possible to mix UMG and BLUI together, and simply use a basic Render Target to create your camera effect

---

<div class="post-metadata">

**Author:** ![JayKavanagh](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@JayKavanagh](https://forums.unrealengine.com/u/JayKavanagh)\
**Post date:** [February 12, 2015, 4:17pm UTC](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338/20 "2015-02-12T16:17:34Z")

</div>

Thanks , I will give it a try and let you know if it works. Should be a cool option for anyone to use.

[Next page](https://forums.unrealengine.com/t/blui-open-source-html5-js-css-hud-ui/20338.md?page=2)
