A little trick needed, to get Blender to smooth-shade an object.

I was recently working on a project in Blender, which I have little experience doing, and noticing that, after my project was completed, the exported results showed flat-shading of mesh-approximations of spheres. And my intent was, to use mesh-approximations of spheres, but to have them smooth-shaded, such as, Phong-Shaded.

Because I was exporting the results to WebGL, my next suspicion was, that the WebGL platform was somehow handicapped, into always flat-shading the surfaces of its models. But a problem with this very suspicion was, that according to something I had already posted, to convert a model which is designed to be smooth-shaded, into a model which is flat-shaded, is not only bad practice in modelling, but also difficult to do. Hence, whatever WebGL malfunction might have been taking place, would also need to be accomplishing something computationally difficult.

As it turns out, when one wants an object to be smooth-shaded in Blender, there is an extra setting one needs to select, to make it so:


Once that setting has been clicked on for every object to be smooth-shaded, they will turn out to be so. Not only that, but the exported file-size actually got smaller, once I had done this for my 6 spheroids, than it was, when they were to be flat-shaded. And this last observation reassures me that:

  • Flat-Shading does in fact work as I had expected, and
  • WebGL is not handicapped out of smooth-shading.


It should be pointed out that, while Blender allows Materials to be given different methods of applying Normal Vectors, one of which is “Lambert Shading”, it will not offer the user different methods of interpolating the normal vector, between vertex-normals, because this interpolation, if there is to be one, is usually defined by an external program, or, in many cases, by the GPU, if hardware accelerated graphics is to be applied.



On to the Future of 3D Web Content: Blend4Web

One of the subjects in Computing which continue to fascinate me, is CGI and so-called 3D Models as well as Scenes, that can be rendered to a 2D perspective View. At the same time, for the more trendy readers who like VR Goggles, those scenes can be rendered to 2 2D Views, just so that there will be parallax between them, and the scene seen with stereoscopic vision.

One of the facts which has been made known is that, sometime in 2020, Adobe plans to retire Flash. On one of my home pages, I actually have a 3D animation which used to run under Flash 11, when compiled with Stage3D support. What I find is that the latest Flash Firefox plugin will not display it for Linux, but Google Chrome still plays it. It’s an animation that should be fixed, but, since I neither have the software anymore which I once used to author it, nor the ability to expect browsers to support Flash in the future, I have just skipped fixing that animation.

What I may do at some point in the future, however, is to create some other sort of 3D content, that can be published as part of Web-pages. And, through the use of HTML5 and WebGL, this is quite feasible. The only question which struck me next was, What sort of platform could I use, eventually, that is Free and Open-Source? And the answer that presents itself, is Blend4Web – Community Edition!

Because this platform, which I’ve tested partially, is fully open-source, the licensing requires that I publish any and all source code used to create my future content, including source code belonging to Blend4Web-CE itself. Thus, to avoid procrastinating on that front, I have made the Open-Source version of that code available Here.

This way, whenever I want to create some 3D content, I will not need to worry much about the licensing requirement. Yet, if my readers want to, they may go to the company’s Web-site, linked to above, and purchase the paid-for version of the software instead, differently from the Open-Source version, which I really prefer and use. (:1)

I want to caution my readers however. This software tree comprises 1.4GB, and if the readers wish to download it, I’d strongly urge them to do so from the company’s Web-site, not mine, because the company has a Content Delivery Network – a CDN – that will enable many downloads, while I do not.

Note: Differently from what some readers have already inferred, Yes, the company Web-site also offers free downloads, of the Open-Source version, which is referred to as the ‘Community Edition’.

(Updated 01/05/2020, 11h40 … )

Continue reading On to the Future of 3D Web Content: Blend4Web

An Example of How WebGL is supposed to Work

In This Earlier Posting, I described how I had recompiled the Atomic Game Engine, to act as a platform running on my Linux laptop ‘Klystron’, from which among other things, I should be able to create games, and export those into ‘WebGL Format’.

WebGL is an ‘HTML5′ specification, which not all browsers support fully, but which essentially allow for hardware-accelerated 3D graphics to run on the browser, as propagated from a Web-server. It has the same gist that the now-deprecated ‘VRML’ used to have, with the exception of being in binary – partially – and being more powerful.

Atomic Game Engine comes with numerous Demos, that are designed to help users like me, learn how to use their system for creating games, and to test their platform.

The following is not a game I created, instead being a simple game delivered through the installation of Atomic Game Engine to my laptop. So this is something which the developers of Atomic Game Engine created, but which I am able to deploy as well, just because I installed Atomic Game Engine. And it may not work on every browser. I hear that Firefox supports WebGL particularly well. And, it is slow to load, because after everything has been said and done, WebGL is still a less efficient platform for 3D content, than actual ‘OpenGL’, or ‘DirectX’ applications would be.

If you load this on some browsers, they will display a message box, stating that ‘A Script is Taking Very Long To Run – Do You Wish To Continue?’ Because we know that this script is supposed to contain a 3D game, presumably we would allow it to keep running. But even when we do, we need to have a fairly strong graphics chip-set, in order for this to render properly. It renders correctly on my laptop ‘Klystron’ – over a network – but not on my server-box ‘Phoenix’, even though both have the same browser version, presumably because of the weak GPU on ‘Phoenix’. And building Atomic Game Engine, did not require me to install any special modules to my system, as a plausible answer to why that laptop is able to play the animation.

On ‘Phoenix’, this content eventually loads, but only displays a black window. And that is correct, even though I am the publisher and code-maintainer for this little project.

Link To An Atomic Game Engine Sample




Atomic Game Engine Recompiled on Laptop

In This Earlier Posting, I wrote that I had installed a custom-compiled version of the Atomic Game Engine on my Linux laptop named ‘Klystron’.

Well today I recompiled all that, specifically so that I would be able to export any hypothetical games I might want to design with that, to Android, thus testing it thoroughly with my newly-added Android NDK.

I finally have the capability to take games that are written in JavaScript, and to export those either to Linux, to WebGL, or to Android.