1. Whole sections of the license are missing, such as section 5 - it's just not possible to agree to something in this state.
2. It's governed by the laws of Texas, so internationally that's not going to work - I'd have to hire a lawyer just to figure out what this means
3. Most importantly, I've no idea why I'd want to use this over embedding Chrome or Servo.
4. There's no ARM support. So no use on RPi, and potentially no use on Mac OS on Apple Silicon, depending on the secret sauce used.
That's before I even start to dig deeper - is it thread safe? Can it fall back to software renderer if needed? Will it be contentious for the GPU with other code that wants to use it?
Only the C & C++ bindings are official, the others are 'community maintained'. Whatever that means.
What I don't get, is why couldn't a dev team just embed WebKit directly - what does this really give? Can it put a browser in game in 3D, or is it a 2D overlay? Will it work with VR / AR?
The website makes a big deal over memory usage, which might be important in some cases, but what about CPU cycles? GPU cycles? Latency? Impact on framerate? Compatibility with Unreal, Unity, Godot, other engines?
I think it's a good project, but there's a lot of considerations before I'd even download for experiments.
Good spot regarding the non-Free licence. Instant deal-breaker. It forbids distribution of the source-code, forbids reverse-engineering, and forbids commercial use.
90% of our code is open-source under LGPL and available on GitHub [1], [2]. The distribution as a whole (and core renderer) is under a proprietary, non-free license with provisions for usage in free software.
Also the license does not forbid commercial use, the free license allows use in commercial software by companies up to $100K in gross revenue. For use in commercial projects beyond that, we have pricing available on our website [3].
3. Chrome (or more specifically CEF -- Chromium Embedded Framework, the one used by Spotify et al.) is significantly more heavy than UL. Memory use is massive. Google doesn't care about API stability and ABI breakage is so common you'll have to keep up with all API changes (the ones published and documented anyway...) to get anything done. Good luck embedding Servo!
4. ARM support is coming.
---
> the others are 'community maintained'. Whatever that means.
I maintain the Rust binding to Ultralight [0] via the CAPI to provide an ergonomic way for people to work with it. Adam is busy improving Ultralight itself, so I find it worthwhile to maintain it. That's what it means.
You know, it doesn't really seem that hard to embed Servo in a Rust application [0]. It's a pretty interesting read.
Anyone know how stable Servo is for this kind of thing? It's not uninteresting as a cross-platform GUI solution or as more lightweight alternative to CEF (assuming it is more lightweight, I haven't done the science on it or anything). Given that you have total control over everything it renders, it's not massively important if it's not 100% HTML compliant or whatever.
Interesting space to watch for the future. Hopefully the Mozilla layoffs don't doom Servo.
However, Servo just isn't ready yet. There are just so many rendering issues that it's worth waiting for it to become more mature. (If you don't believe me, open https://psychonautwiki.org with Servo..)
I'm using headless UL to statically render articles on-demand so that CDN caches can be warmed up at each PoP so that people from less fortunate areas (middle-africa, southern americas, researchers in either pole of the earth -- yes we had them, former soviet countries, ..) can access the wiki just like any other user would. It strips out the unneccessary bells and whistles.
Also I think Adam is a great person and I think it's worthwhile to support his project.
"What I don't get, is why couldn't a dev team just embed WebKit directly - what does this really give? Can it put a browser in game in 3D, or is it a 2D overlay? Will it work with VR / AR?"
It really is not that simple. Rendering a modern webpage or webapp requires a lot of components. You can't just take webkit and call it a day. For example in the chromium engine Blink which is the Webkit fork doesn't event render pages. It consumes HTML and CSS and produces "display lists" i.e lists of drawing commands. Those are fed to a rasterizer engine that must maintain a whole stack of trandormable layers which are managed in various render trees. Finally pages are radterized in tiles and then composited together for the final image that is show in the viewport. All of this covers millions of lines of code on top of Blink! And we're not even talking about things such as executing JS or syncing JS input handlers with the rendering or doing the actual page loads over HTTP/S or handling windowing and platform APIs and user input etc. All of which are really more or less essential in order to make anything that is actually useful.
FWIW Ultralight isn't tied to GTK or any windowing system (API is platform-agnostic), also the core Renderer API doesn't even require a run loop (this is vitally important if you're integrating HTML UI into complex environments like games and headless apps).
Hi there, lead dev of UL here (seems HN found our beta :)):
1. That Section (5) is left intentionally reserved (empty) since the commercial version of the contract provides commercial license grants. This is typical when offering multiple versions of a contract.
2. Contracts are typically governed by laws of a certain government (this is called venue). You can indeed enter into an agreement with another party using a venue in another country. (FWIW I agree the Free License is a bit too unwieldly-- I'm going to switch to an slimmer alternative that's more grokkable)
3. You would use UL for lower-level control over the embedding itself-- the library allows you to override file system loaders, font loading, drawing/rasterization, clipboard integration, and drawing itself (via GPU display lists). You can think of it like a smaller, lighter, cross-platform WebKit that's way more "hackable" and is designed to display HTML in an existing app rather than function as a standalone browser (right now, we're primarily used in games).
4. ARM64 support is on the way, there'll be an Apple Silicon port later this year.
For your other questions:
- [Is it thread safe?] This is in our docs, the API is not currently thread safe but you can run the whole thing on another thread. (an upcoming multi-process RPC layer is being built around the core API, and that will be thread-safe/async)
- [Can it fall back to software?] Latest build of UL can fully render on CPU, so yes.
- [Will it be contentious for GPU?] The overhead is minimal. Views are painted on an as-needed basis to GPU display lists, you can see the full GPUDriver interface here [1].
- [Only the C & C++ bindings are official] Several users of our community maintain open-source bindings for other languages, we will move into supporting them directly as the project grows.
- [Why couldn't a dev team just embed WebKit?] As one who has worked on exactly that for 11 years, it's really not that simple. The API of WebKit itself is not designed for embedding inside an existing application, and also much of the design decisions of the engine itself is designed to build a browser, not render HTML. Furthermore, most WebKit ports are tied to a specific windowing-system which is a big deal breaker if you're embedding HTML inside exotic, cross-platform environments likes games and headless server apps.
- [What about CPU cycles? GPU cycles? Latency?] Sure I can put up more benchmarks to that effect, the website is undergoing a refresh for the 1.2-stable release so it's out of date.
- [What about Unreal, Unity, Godot?] Several users have already used the API to integrate into Unreal and Unity, we will make an official plugin for all three later.
Hope this helps clear things up! I'm usually available in Discord [2] if you have more questions.
This seems like it’s based on WebKit, parts of which are LGPL. Did they not modify it at all? (If so, why should I use this?) If they did, where is the code?
UL uses a fork of WebCore/JavaScriptCore (the layout engine and JavaScript engine from WebKit). It is indeed modified (been working on it 7 years) and released open-source on GitHub.
Yep, We hit a wall when developing Awesomium-- long story short, the vision for Chromium long-term didn't match with our design goals so we announced to the community that we're starting over with something new (which turned out to be a minimal WebKit-port, eg. Ultralight).
From a business standpoint, we were offering paid commercial support for not just Awesomium but all the Chromium-related parts and that surface area had grown to be way too large to be maintainable. For the product to succeed we had to refocus efforts on building a solution we could fully own and met the requirements of our core market-- and that took about 6 years of R&D.
Hi there, lead dev of UL here (we didn't post the link, HN just found our beta :)).
That top-level repo is just our packager/samples, 90% of our code is open-source and available on GitHub (released under LGPL), see our WebCore [1] and AppCore [2] modules.
The product as a whole contains two proprietary modules which are indeed non-free but allow free use in non-commercial and commercial projects up to $100K in gross revenue.
The website https://ultralig.ht/ says "No source code for proprietary modules." for the free version. So it's technically not an open source project and therefore not a suitable candidate for my projects.
Anyway the sole core benefit proposition compared to chrome seems to be less memory use.
Lead dev of UL here, we didn't post the link, and our GitHub repo is def not clickbait (the top-level repo is just the packager and samples), 90% of our code is open-source under LGPL and available on GitHub [1], [2]. The product as a whole is under a proprietary, non-free license with provisions for usage in free software [3].
The code is there, but not all of it, as I understood - except the "Proprietary GPU Renderer". And yes -
"Ultralight is free for non-commercial use and free for commercial use by companies with less than $100K gross annual revenue"
Not all code is there. The website https://ultralig.ht/ says "No source code for proprietary modules" for the free version. If you want to use the technology in your free application then you tnerefore have to depend on a proprietary closed-source library. And as it seems only to save a bit of RAM. Better use Qt.
To be fair, Ultralight supports the console platforms, which it cannot do with open source code (not allowed by the developer agreements.) As such, it would already have to have a way to deal with non-public binaries or sources in the tree. In addition, a GPU renderer that plays nice as an embedded library, and is performant and can properly render html is not a small feat of engineering. I cannot entirely blame the author(s) for keeping that part proprietary. I just question the wisdom of it in the face of free competition like WebKit, CEF, Sciter or Qt.
Yep, we maintain an Xbox port and are porting to PS4, PS5, and Switch next.
Yes, the GPU renderer (and CPU renderer) took about 4 years of R&D alone to get to a usable state (we started on GPU rasterization long before WebRender was even around).
FWIW, a large number of our customers need commercial support and have complex integration concerns that go significantly beyond what those offerings provide (just in the past week, we've been doing custom development for several game studios to get our renderer working in their engine on their platforms).
Also we fully intend to stay current with WebKit trunk (we use a fork of their WebCore/JavaScriptCore modules) since a number of our users need to support modern HTML/JS/CSS (latest build supports ES6 modules, WebAssembly, and more).
I don't understand that. The readme says "Ultralight is a lightweight, cross-platform, HTML rendering engine for desktop apps and games." How does this fit with your argument?
> which it cannot do with open source code (not allowed by the developer agreements.)
Consoles, as in PS4, XB1, soon PS5..etc. Elsewhere in the thread the author said that some of these are already supported, and others are coming soon. Access to the SDKs for those, which you would need to run something like UL, is governed by contracts that you as a developer sign with the platform owner -- Sony, Microsoft, Nintendo, etc.
These agreements very rarely (read: never) allow publishing of the SDK sources in any fashion. Even simply exposing code that calls into SDK functions would be in violation.
You don't get access to the SDK unless you sign the contract, and if you sign the contract and breach it, they have legal cause against you. Usually if you want to use third-rdparty software for these closed platforms, the third-party and you must both have developer agreements with the platform owner. This of course excludes software that you as a developer ported to the platform on your own.
Ok, I see, you're talking about home video game consoles, not command-line interfaces. I'm not home console developer (nor user); one reason is that it ties one too closely to the proprietary technology of individual manufacturers. But I see your point. Your arguments do not contradict my statements. I only stated that not all source code are available in the free version and therefore it is not an open source product.
GitHub says the project is 100% CMake, and I didn’t see anything to make it ignore the large amount of C++ that I would expect to underlie this project. Do you know where I could find the parts you’re talking about?
Proprietary renderer (not even source-available; Linux binaries linked against god knows what version of libc, libstdc++, etc) ontop of WebKit? No thanks.
Edit: I mean, sure, you could use it in your proprietary Electron app to make it more lightweight. At least on Windows, macOS and some Linuxes, the rest of users is left out then, but those free software enthusiasts are unlikely to use your software anyway.
This lead me to think that there are huge amount of legacy HTML functionality that Electron could potentially drop if it was possible. Electron doesn't really need to care about breaking the web. So there's definitely room for alternatives.
There probably is a lot of legacy stuff in there but I suspect that most of it is deeply integrated into the needed functionality.
That said, I suspect that many of the more modern JS APIs which are organised as separate modules are much easier to exclude when building something like Electron. I'm talking about these kinds of APIs: https://developer.mozilla.org/en-US/docs/Web/API
Many APIs there to exposed things from deep inside the rendering engine, but there are still plenty left which are likely separate, like Bluetooth, Gamepad, Ambient Light, Beacon, IndexedDB, Image Capture, Geolocation, Payment request, Web Audio, etc.
Builds of Electron with exotic APIs removed could be good although I'm sceptical of whether that would bring the run-time memory use down much, i.e. what (API) you don't use, didn't hurt you anyway.
A strict subset, chosen for the greatest intersection of flexibility for developers, simplicity and performance with good documentation on how to write directly for it might go over well.
The hardest part for maintainers would be saying no when everyone inevitably asks to expand the feature-set.
Is there an Electron alternative that uses the OS's rendering engine (Webkit on macOS, Edge on Windows), for developers who think that bundling a whole browser with their app is not the right tradeoff?
I've found two that are promising. wails [1] for Go and pywebview [2] for Python. Oddly enough, I haven't found a decent node package that is maintained and documented.
Here is a list of lightweight alternatives for Electron: electrino, neutralino, Quark, Ultralight, Miniblink, Deskgap, WebWindow, litehtml, cztomsik/graffiti, yue, nodegui.
It looks strange to me that it tries to use HTML, because then it should be compatible with Web APIs and should render the same. Then it would be basically a browser, not very different from what is used today in Electron.
But if it will differ from Web platform, why not to just make lightweight alternative DOM-like API.
Been there, done that. Qt has had a renderer for a reasonable subset of HTML4 and CSS2 since the Qt 3(?) days. If you see a Qt app and there's colored text or bold/italics inside a label or editor, that's all done using that flavor of HTML. It gets rendered through the standard QPainter engine.
In the realm of lightweight html renderers I've taken a liking to litehtml ( https://github.com/litehtml/litehtml ) - though it isn't quite as fully featured as this.
It's nearly impossible to write a new browser engine that is compatible with all the legacy mess on the wild web, but for packaged webapps a modern minimal engine is exactly what they need.
It isn't open-source in the "FOSS" sense. You can't have such terms in a FOSS license.
However, you can have parts of a codebase be FOSS licensed, if the license is compatible with non-FOSS code. BSD, MIT and Apache licenses allow this, copyleft licenses like the GPL don't.
GPL (and others) allow such a model as well. There is nothing in the GPL preventing me from selling for as much as I like. The buyer however has to receive the source code (upon request) and can share it for free (as in beer) if they like.
I'm taking about using a license that has provisions such as "can only be used for free by entities with less than $100,000 in revenue" (this case) or "must not be used for evil" (jslint). Such a license would not be considered a free software license, because it restricts the use:
I had a brief look at the github repositories and don't think that all source code is available. At least I'm missing the source code of the core renderer. Maybe I didn't look close enough yet though.
Ok, the website https://ultralig.ht/ says "No source code for proprietary modules." for the free version. So it's technically not an open source project. I won't add closed-source binaries to my open source projects, so unfortunately this technology is not interesting, regardless whether it's good or not.
Revery is fully native and doesn't use parts of web platform. It uses ReasonML, that is dialect of OCaml and has its own implementation of platform and renderer.
According to the Architecture section of the GitHub page [1]:
> Ultralight is a new port of WebKit combined with a new [proprietary] lightweight renderer intended specifically for embedding in apps and games.
And the Licensing section:
> Ultralight is free for non-commercial use and free for commercial use by companies with less than $100K gross annual revenue. For more info see LICENSE.txt
For once I want to see "heavyweight" in the sales line... Just to see how it compares to all these "lightweight" offerings. Once you add in all the corner cases and bug fixes it seldom stays "lightweight". Good job on releasing it though.
How does the accessibility story look like? If there's no accesibility, the usual disclaimers apply, get legal advice before building anything professional with it. Be aware of not just current laws, but future ones, especially those we definitely know are coming.
Unfortunately, Ultralight has no accessibility support. I brought this up when Ultralight was initially announced a couple of years ago. So I hope that so far it is only being used by game developers.
Also, while it's good that you bring up accessibility on threads like this one, I don't think it's a good idea to go straight for the threat of legal action. The natural response to that tactic is to question whether there will really be legal reprocussions, and that's a distraction from the real issue. Instead, I tend to focus on the moral problem of blocking people from doing their job, getting their education, etc.
> If there's no accesibility, the usual disclaimers apply, get legal advice before building anything professional with it.
I never heard about any "usual disclaimers", what exactly are you referring to?
AFAIK nobody is going to be suing developers for their software and the worst that can happen is people with accessibility needs simply not using your programs. The main issue is with employees with accessibility needs being unable to perform their work due to your software and having no other alternative - this is a case where their employer (not you, unless you are said employer) can be sued.
But beyond that i never heard anything about requiring legal advice before using any sort of UI framework for general professional use (TBH that sounds absurd).
No developer is going to be sued for their application having no accessibility features. The one who might be sued is an employer forcing some employee to use the software to perform their task without any other alternative, essentially making it impossible for that task to be performed by that employee. Unless you are in a position to cause this, you are not going to be affected (and even then, you getting sued is very unlikely unless you are said employer).
In practice the worst that can happen to you is people with accessibility needs not using your software.
Companies are obliged to provide necessary tools to their employees to perform the tasks that they are hired to perform. This includes accessible tools for people with disabilities as enforced in most legal systems.
If your tool is not accessible, companies cannot meet this obligation and will choose a competitor who does.
I can enable accessiblity features and API to make the library more amenable to screen readers and other modes of browsing. So far the library has primarily been used in games (which have less accessibility concerns) so we've been focusing on that segment the last 6 months.
I think that is if you want the additional stuff like support. You can still have $5 in revenue and purchase a license, that will make you fall into the first category and have to pay $2000.
You don't have to purchase a license, but you can if you want.
I'm pretty sure this is what Awesomium became. When I last looked into Awesomium (like 8 years ago now) its development seemed to have stagnated and the developer was trying to find a way to monetize it.
IIRC he shutdown the website and abandoned twitter leaving paying customers high and dry. There was some talk of it last time this project made the forum rounds.
We didn't abandon anything, we announced to the community that we were stopping development of Awesomium (our previous Chromium fork), are going to build something new (which turned out to be UL, I wrote the rationale elsewhere in this thread), and continued to support our paid customers for years after (all licenses came with a 1 year annual support contract with option to renew, we would be in contract violation if we didn't).
We did stop maintaining the free online support community which I think is where this sentiment came form. Users were upset that there were no new versions of Awesomium and there was a 4 year gap before the first alpha of Ultralight was released which left a number of users rightfully annoyed.
I personally couldn't promise that were _would_ be a successor project since Ultralight was so experimental (the GPU renderer alone took about 4 years to get working on all platforms). That lack of communication and subsequent gap in updates is what led users to believe the project was abandonware (luckily, I'm here to say it isn't and we're still alive!).
FWIW, Ultralight was actually built in tandem using internal feedback from our existing customers. Many of our current users are ex-Awesomium users.
I'd like to find out more about this, because I haven't heard of that at all. That I haven't heard is not surprising though as I last looked at Awesomium a very long time ago.
If you're writing desktop apps using an HTML/CSS interface, I wonder if "lightweight" is really a concern? I don't work on any such projects, but I'd probably prefer something established with a community (electron) if the only advantage is size (they mention memory usage too, but no specifics).
It's definitely still a concern! And our community is growing (come check out our Discord [1]).
Our advantages are much more than memory usage-- it's also distributable size, low-level integration, single-process mode (no external renderer processes), GPU rasterization (and integration into custom GPU drivers), and custom modification of the library itself (most of the library is open-source and on GitHub-- it's much more amenable to "hacking" on than Chromium so it's a better fit if you need a custom HTML rendering solution than Electron).
We're still building out our desktop app runtime (AppCore) to match the API of Electron, but the low-level renderer is already finding a solid foothold inside of games (PC, macOS, and consoles) and headless server renderers.
My understanding: It's common to use Electron to build cross-platform desktop apps, but that basically ships a browser and a web server inside every app, so it takes a lot of resources.
If I am to locally run some HTML + CSS + Javascript app, isn't it better to just give my clients exactly some HTML + CSS + Javascript files and let them use their preferred browser to use it?
As for Electron, each time I see those types of applications, they are uninstalled faster then light. One reason why I stopped used Skype in 2014, they made it Electron app. Never looked back.
1. Whole sections of the license are missing, such as section 5 - it's just not possible to agree to something in this state.
2. It's governed by the laws of Texas, so internationally that's not going to work - I'd have to hire a lawyer just to figure out what this means
3. Most importantly, I've no idea why I'd want to use this over embedding Chrome or Servo.
4. There's no ARM support. So no use on RPi, and potentially no use on Mac OS on Apple Silicon, depending on the secret sauce used.
That's before I even start to dig deeper - is it thread safe? Can it fall back to software renderer if needed? Will it be contentious for the GPU with other code that wants to use it?
Only the C & C++ bindings are official, the others are 'community maintained'. Whatever that means.
What I don't get, is why couldn't a dev team just embed WebKit directly - what does this really give? Can it put a browser in game in 3D, or is it a 2D overlay? Will it work with VR / AR?
The website makes a big deal over memory usage, which might be important in some cases, but what about CPU cycles? GPU cycles? Latency? Impact on framerate? Compatibility with Unreal, Unity, Godot, other engines?
I think it's a good project, but there's a lot of considerations before I'd even download for experiments.