Next step is to replace these square models by something more actual. For example, by this: I picked specifically this model for it's challengingly curved shapes. Just in case, this is 1935 Duesenberg SSJ Speedster, 1:64 scale model. In order to implement that, we'll need to extend our ModelBuilder and ModelLoader functionality. Also we'll need […]
Chapter 38. Hierarchical models
Now we are ready for more complex models, consisting of several elements with individual behavior. For example - car, where body will be a parent (root) element, and wheels - child elements. For both, body and wheel, we'll need separate model descriptors and separate classes, which will handle their behaviors. 1. In Windows File Explorer […]
Chapter 37.2. GitHub
Just to make sure that we are on the same page, let's synchronize our environments. You can download full current Project repository from https://github.com/bkantemir/_wg37 Windows solution, x86: _wg37-main\a997modeler\p_windows\p_windows.sln Android solution, ARM64: _wg37-main\a997modeler\p_android\p_android.sln Important changes here: In order to untie the project from C:\CPP, all paths in projects properties were converted to relative form. Like ..\..\engine […]
Chapter 37. Mesh optimization
Though the model is completely ready now, still we have 1 more issue to resolve: Currently our model consists of 316 vertices and 144 triangles (432 indices). Actually, not too much comparing to 3D editors. But still, how come so many?? Well, root box for instance: 6 sides, 4 vertices each = 24 vertices 12 […]
Chapter 36. "Glass" effect
The model is almost ready. Two remaining missing pieces are: For clear-film we don't even need to write a new shader. We will use our "mirror" shader (as for gilded prints) with white noise as a main texture (uTex0) and will "translate" it to semi-transparent 8x1 texture glass01.bmp (uTex3), imitating glass reflection. It's a plain […]
Chapter 35. "Wire" shader
Here I want to add a golden sealing ribbon on the pack. It will be a line, a sequence of points instead of regular triangulars mesh. It will require: A set of new tags in ModelLoader New lineWidth property in Material class In DrawJob we'll need to adjust lineWidth depending on distance Additional shader's functionality […]
OpenGL ES vs Vulkan vs Angle
Sure, I had doubts regarding my initial OpenGL ES choice. Now I have some answers: Vulkan Is it good? Well... Yes: However, I'm mainly interested in how cross-platform it is. Unfortunately, not exactly. Besides: Actually, quite enough to exclude it from my consideration… OpenGL ES The situation around OpenGL ES seems to me much more […]
Visual Studio: the file contains a virus?!
A few days ago I started receiving the following messages from Windows Defender: Microsoft Visual Studio: Unable to start program 'C:\CPP\...\w.exe'. Operation did not complete successfully because the file contains a virus or potentially unwanted software. At the beginning it didn't bother me much, since project rebuild usually helped. But finally Defender "promoted" me (along […]
Chapter 34. Adjusting Material
We are STILL trying to "draw" the joint (slit) between the pack and the lid, as a small normal map applied to existing textured mesh's fragment. At this point we do have fragments with their own "native" Materials. In the last sample we just replaced them (Materials) by Phong green. Instead we need to use native Materials, but with added […]
Chapter 33. Polygons Intersection
Just a friendly reminder: we are still trying to "draw" the joint (slit) between the pack and the lid, as a small normal map applied to existing textured mesh's fragment. Like this: In previous chapter we implemented a concept of selecting and manipulating "marked vertices/triangles groups". So, now we can select one (in this sample - "box_right"), duplicate […]