4
\$\begingroup\$

I realized that I need an HTML-like UI in my game, because by myself I wouldn't be able to achieve such effects (divs, text, coloring, and styling).

So I started to look around for a HTML Engine for C++, and I found Sciter but it's built completely on top of the Win API and I just can't get it to work/debug (because it lacks of decent DOCs too). Now, I'm wondering if there is some very simple engine (I just need HTML and CSS, no JS) and SDL friendly (should have some functions like create, update, render, ...).

\$\endgroup\$
1
  • \$\begingroup\$ Sciter's author is here... I've added an option to use Sciter inside DirectX sciter.com/sciter-and-directx and there is an ongoing project for the same with OpenGL and so SDL. That's just in case. \$\endgroup\$ Commented Feb 5, 2016 at 4:58

1 Answer 1

6
\$\begingroup\$

Take a look at Awesomium. I have integrated it to SDL before and the process was fast. The biggest thing you have to deal with is translating SDL events to Awesomium. Otherwise the rendering is really easy, you can just query pixel data from Awesomium into an SDL surface IIRC, and then render that to your game.

\$\endgroup\$
7
  • \$\begingroup\$ Garry's Mod uses Awesomium, and though I haven't used it myself, other people frequently complain about it being outdated and buggy. \$\endgroup\$ Commented Jan 10, 2016 at 21:44
  • \$\begingroup\$ Garry's mod was released in 2004 which might have an effect regarding being outdated. \$\endgroup\$ Commented Jan 11, 2016 at 5:57
  • \$\begingroup\$ @immibis Garry's Mod uses Source GUI, doesn't it? So Source is using Awesomium, no? \$\endgroup\$ Commented Jan 11, 2016 at 8:10
  • \$\begingroup\$ @Xriuk It supports Source's GUI components, and a bunch of GMod-specific ones. \$\endgroup\$ Commented Jan 11, 2016 at 9:04
  • 1
    \$\begingroup\$ I only use Visual Studio so I don't know anything about workarounds. I only used Awesomium for a short period of time, but I did not have any problems with it. \$\endgroup\$ Commented Jan 11, 2016 at 19:09

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.