Major new vesion of Ab4d.SharpEngine published

by abenedik 5. July 2024 12:48

I am really excited that I can present you a new Ab4d.ShareEngine version 2.0!

The version 1.0 was already very capable and could show 3D graphics on platforms from tiny Rasberry PI to mobile devices and high end PCs. But if you know the Ab3d.PowerToys and Ab3d.DXEngine libraries then you missed some of the features. Now, with version 2.0, many of those highly requested features are available.

Here is a list of some of the major new features:

  • Added support for rendering pixels and point-clouds. There is also a sample that can import point-cloud data from .ply and .xyz files.
  • Added ModelMover, ModelScalar and ModelRotator that can be used to move, scale and rotate selected 3D objects.
  • Added InputEventsManager that can be used on SceneNodes to subscribe to Clicked, Entered, Exited, Dragged and other mouse and pointer events.
  • Added MultiMaterialModelNode that can render a single mesh with multiple materials.
  • Added support for slicing SceneNodes with a 3D plane.
  • Significantly improved performance of generating edge lines and selecting 3D lines.
  • Added support for triangulation and extrusion of shapes with holes.
  • Added new sample that shows how to create a custom effect by using your own shaders.
  • Added full support for Windows Forms with new Ab4d.SharpEngine.WinForms library that provides SharpEngineSceneView control for Windows Forms.
  • Added fully managed glTF file importer and exporter that can be used on all platforms and does not require any native library (that is required by Assimp importer).
  • Added support for using Vulkan backend in Avalonia. This way the whole application (UI controls and 3D scene) is rendered by Vulkan. This requires Avalonia v11.1.0 (currently in pre-release version).

If you are following the development of Ab4d.SharpEngine, then you may be surprised by the new version number. I always said that the next version would be version 1.1, but now version 2.0 has been released. The reason for that is that there are also some breaking changes. In the previous version many classes, enum values and parameter names used the "mouse" word. But with the new cross-platform environment the "mouse" is no longer the correct word and has been replaced by "pointer" by many frameworks (Avalonia, WinUI). This has also been done in SharpEngine, for example: MouseCameraController => PointerCameraController, MouseButtons => PointerButtons, MouseAndKeyboardConditions => PointerAndKeyboardConditions, etc. In most cases the old class or enum values still exist but were marked as obsolete with a message about how to change its name. I know that such changes are not nice for users, but they must be done to modernize the API.

Here are some of the screenshots of the new version:

Point-cloud importer that can import data from .ply and .xyz files

ModelMover, ModelScalar and ModelRotator

Sliced 3D model

Triangulated and extruded 2D shape with holes

glTF importer

WinForms samples with 3D graphics by Ab4d.SharpEngine

 

Images are nice, but it's even better to see the new features in action. To do that, get the latest version of the samples from GitHub

Note that the Samples project is not updated only on each release but new samples may be added between releases. So, it is best to subscribe to changes or check the commit history of the Samples from time to time.

Most of the new features should be easy to understand and use. So let me describe in more detail only two of them.

3D models are usually created by a 3D modeling application and then saved in many possible file formats. When we wanted to show such 3D model in our application, the Ab4d.SharpEngine library provided two options. The first was to save the file in the .obj file format and the import it by using ReaderObj that is part of the core Ab4d.SharpEngine library. The problem was that obj file is missing many features (for example, object hierarchy and transformations) and is only text based, so files can be large and take longer to read. The other option was to save the 3D model to some of the common file formats like .fbx, .gltf, .dae, etc and then use Assimp importer to import the models. This works well for many file formats, but this requires the use of a third-party native Assimp importer. When you are developing a cross-platform application, this is a problem. The samples come with native builds for Windows and Linux. It is also possible to compile the Assimp library for macOS, Android an iOS, but this requires some special skills and you need to distribute all the native libraries with your application. A much better way would be to have a fully managed importer where only one dll can be used on all platforms.

Because of this, a new Ab4d.SharpEngine.glTF library was developed. It provides a fully managed cross-platform glTF 2 file importer and exporter. The glTF 2 file format is a modern file format developed by the Khronos group and can store meshes, hierarchies, materials, transformations and animations in a text or binary format. Many online and offline converters can convert to glTF from many other file formats. The new library can also export the SharpEngine's SceneNodes to glTF file (not all SceneNode types are supported yet). Please note that glTF 2 file saves materials as Physically-Based-Rendering (PBR) materials. This requires some transformations of the StandardMaterials to PBR materials and back. In the next version of Ab4d.SharpEngine I plan to add support for rendering PBR materials.

Another new feature that I would like to talk about is the support for creating fully Vulkan based applications by using the new version of Avalonia (v11.1.0-rc2 at the time of writing). Vulkan API is a cross-platform API that is used to communicate with the graphics card. It is used by the Ab4d.SharpEngine to render the 3D scene. But until now, there were no UI framework that would use Vulkan. Some of the frameworks use only DirectX (WPF, WinUI) or a combination of DirectX and OpenGL based on the current platforms (Avalonia, MAUI). In many cases this requires copying rendered 3D scene to some other format before it can be shared by the UI (but the rended texture can still stay in the GPU memory). In some cases, sharing is not possible and this requires copying the rendered image to the main CPU memory, creating a bitmap (WritableBitmap) and sending that back to the GPU by the UI platform. But with the new Avalonia, we can finally create an application that is 100% rendered by Vulkan. This provides very fast UI rendering and great integration with Ab4d.SharpEngine. Currently, this is possible only on Windows but in the future other platforms will be supported as well. You can test that by starting the new Ab4d.SharpEngine.Samples.AvaloniaUI.VulkanBackend solution.

Note that currently there are two versions of Ab4d.SharpEngine.AvaloniaUI libraries available. One has version 2.0.8951. This one is using the Avalonia version 11.0.11 (the last official version). Then there is another Ab4d.SharpEngine.AvaloniaUI library that has version 2.0.8953-rc1 (pre-release). It requires Avalonia version 11.1.0-rc2 (also pre-release). Those two pre-release versions are required to use Vulkan as a backend. When an official Avalonia version 11.1.0 is released, I will also provide a new version of Ab4d.SharpEngine.AvaloniaUI that will not be marked as pre-release.

To see the list of all changed in v2.0 check out the SharpEngine history web page.

Let's finish with a quick view into the future. 

Next week, I plan to publish a new bug fix release for Ab3d.DXEngine. In the past few months some bugs were fixed and it is now time to release that. I will also be adding new samples for Ab4d.SharpEngine and updating some of the existing samples. Before the end of the year I expect to release another new version of Ab4d.SharpEngine, Ab3d.PowerToys and Ab3d.DXEngine.

The plans for Ab4d.SharpEngine include work on the core of the engine with support for background resource creation (top priority) and multi-threaded rendering (hopefully). There will also be support for post-processing and improved pixel rendering options. I would also like to add support for Uno platform, PhysicallyBasedRendering effect and rendering 3D lines with arrows.

For both Ab4d.SharpEngine and Ab3d.DXEngine I would also like to provide support for importing STEP and IGES file formats that are commonly used by CAD applications.

There are lots of plans. But I am sure that many of you have some additional ideas and requirements. In this case please contact us.

And finally, I wish you a nice and relaxed summer and shiny 3D graphics in your applications.

Tags:

SharpEngine

Ab4d.SharpEngine v1.0 published

by abenedik 8. December 2023 11:30

Ab4d.SharpEngine logo

Ab4d.SharpEngine v1.0 has been published!

The new cross-platform 3D rendering engine is ready for apps that work on Windows, Linux, macOS, Android and iOS. The engine uses Vulkan, which is a next generation graphics API that provides high-efficiency, cross-platform access to modern GPUs. The engine is also built by using the latest .Net technologies like Numerics and harware intrinsics. The combination of Vulkan and highly optimized .Net code provides super fast rendering. Based on long-time experience with Ab3d.PowerToys and Ab3d.DXEngine I have designed the API for the new engine to be very easy to use. Especially users of the Ab3d.PowerToys and Ab3d.DXEngine libraries should feel right at home.

The new engine can work on almost all devices that support .Net runtime. It can run on high end PCs and tiny Rasberry PI computers (with full hardware accelerated graphics). By using a software rendering LLVM pipe, the engine can also run on systems without a graphics card (for example, a web server, virtual machine or tiny embedded device). This provides many new very interesting options, for example, showing 3D graphics on a display that controls a CNC machine and runs on a Rasberry PI or some other embedded device. See here and here for more info.

The Ab4d.SharpEngine can be integrated into almost any UI framework. The following UI frameworks are currently supported: WPF, WinUI 3, Avalonia, MAUI, SDL / Glfw, LinuxFramebuffer. Better support for WinForms is coming soon. In all other UI framework it is also possible to render to an offscreen texture and than show that as a bitmap. Another proof that the engine is meant for any 3D developer is also that the engine supports any 3D coordinate system (y-up or z-up; left or right-handed; see the second screenshot below). What is more, the engine's main assembly, Ab4d.SharpEnine, does not have any third-party dependencies. To be able to provide great cross-platform capabilities, the engine even have a build-in png reader and writer, so you do not need to use platform specific bitmap libraries.

The first version of Ab4d.SharpEngine still lacks some of the features from Ab3d.PowerToys and Ab3d.DXEngine. But it should already have all the tools to create great apps with 3D graphics. Here are some of the screenshots:

3D model from fbx file with shown edge lines
Custom 3D coordinate system with Ab3d.SharpEngine
Ab4d.SharpEngine in an Avalonia UI application on macOS (Input events sample)
Ab4d.SharpEngine in an Avalonia application on Ubuntu Linux (3D lines sample)
Ab4d.SharpEngine in a generic SDL / Glfw application on Rasberry PI 4

The easiest way to start exploring the new engine is by checking the samples project that is hosted on GitHub: https://github.com/ab4d/Ab4d.SharpEngine.Samples. Note that some of the existing samples will be improved in the following days and many new samples are planned to be added.

The Ab4d.SharpEngine is distributed only by NuGet packages and cannot be installed by using a commercial version installer (as it was possible with other products). To use the engine it needs to be activated by calling the SetLicense method. The samples come with a special license that can be used only by the samples. To use the engine in your applications, you will need to get a trial license from ab4d.com/trial (no email is required) or purchase a commercial license and then activate the commercial license.

The purchase options provide the standard "Single developer", "Team developer", "Site developer" and "Corporate developer" options that define how many developers are allowed to use the library. The standard license allows developing applications for Windows, Linux and macOS - it is called a "Desktop developer" license. To develop apps for mobile devices (Android and iOS) an additional "Mobile developer" license is required. With a standard commercial license you are allowed to use the Ab4d.SharpEngin to create applications for uses that do not have the Ab4d.SharpEngine license. But if you want to create a commercial library that uses Ab4d.SharpEngine, then a new "SDK license" is required. Contact us for more information.

To celebrate the launch, there is a 20% discount for all Ab4d.SharpEngine licenses. The discount is valid until January 7th, 2024.

I know that some of the Ab3d.PowerToys and Ab3d.DXEngine users did not look at the development of a new engine with a lot of gratitude. That development meant that less time was dedicated to the existing engines. I admit that lately not a lot of work has been done for other libraries. But this will change now. Next week, a new maintenance version of Ab3d.PowerToys and Ab3d.DXEngine will be published. That version will have some fixes and smaller improvements already implemented in the last few months.

What is more, for Q1 2024 I plan to release a new major version of the Ab3d.PowerToys and Ab3d.DXEngine. The following are planned new features:

  • Add support for Screen Space Ambient Occlusion (SSAO) that will significantly improve the visual quality.
  • Add new options to render pixels and point clouds (world-size pixels in addition to screen-size; render circular pixels or pixels with custom textures).
  • Add support for rendering 3D lines and line segments to an object ID bitmap (can be used for faster line hit testing).
  • Add options to copy only part of the object ID bitmap from GPU memory to CPU memory - this would make checking for hit objects much faster.
  • Trying to improve the performance of calculating edge lines by using oct-tree.

For 2024, I would also like to introduce a new product that would allow importing 3D models from STEP and IGES file formats that are commonly used by CAD applications. Later, there would also be improved support for geometric and surface modeling that is based on mathematical surfaces and not triangles.

So, it looks like 2024 will be another very busy year.

Please try the new Ab4d.SharpEngine. I really hope you will like it and that it will help you build awesome apps and bring 3D graphics "where no 3D graphics has gone before" (adapted from).

Tags: , ,

SharpEngine

Ab4d.SharpEngine beta 2 comes with many new samples

by abenedik 18. April 2023 09:30

The second official beta version of the new cross-platform 3D rendering engine has been published. You can get the new samples from: https://github.com/ab4d/Ab4d.SharpEngine.Samples (on GitHub also click on the Watch button to be informed of future changes).

The new version comes with many new samples that demonstrate a lot of functionality of the new engine. There are samples that demonstate cameras, mouse camera controller, materials, lights, different 3D objects and lines, model importers and animation. The following screenshot shows the samples running in a WinUI 3.0 application:

Ab4d.SharpEngine Vulkan samples in WinUI 3.0 application

You can see that the samples are organized in a similar way as the samples for Ab3d.PowerToys and Ab3d.DXEngine.

Because the engine can run on multiple platforms and UI frameworks, most samples are now defined in a common samples project (Ab4d.SharpEngine.Samples.Common). That project uses a generic UI provider that can create UI elements like Labels, CheckBoxes, ComboBoxes, Sliders, Buttons and other elements that are required for the sample. Then the project for the specific platform references that common project and provides rendering of the UI. This way the same sample code can be used for WPF, WinUI and Avalonia. The Avalonia sample works on Windows and without any change in code the same sample also runs on Linux and macOS (see screenshot with Rider IDE in the back):

Ab4d.SharpEngine Vulkan samples in Avalonia application running on Linux

Ab4d.SharpEngine Vulkan samples in Avalonia application running on macOS

There are also two special samples for Android. They show only a single 3D scene. Their purpose is to demonstrate two different ways on how to initialize the engine in Android. From there on, the code to create and manipulate the 3D scene is the same as for desktop operating systems. The following screenshot shows the engine running in Android:

Ab4d.SharpEngine sample in Android application

The current version does not support iOS yet. The problem there is that AOT (ahead-of-time) compilation that is required for iOS does not support function pointers (https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/proposals/csharp-9.0/function-pointers) that are used by the engine to communicate with Vulkan. It is interesting that for Android or desktop it is possible to use AOT compilation and there function pointers work without problems. If you have any recommendations on how to use function pointers on iOS, I would be glad to hear that. Otherwise, it seems that a special build of SharpEngine will be required for iOS. That build would use a different and less efficient way to call Vulkan functions (using standard delegates and UnmanagedFunctionPointer attribute). This needs some additional research so the support for iOS has been moved to the next version.

The major goal of this beta version was to provide new samples that demonstrate how to use the engine. But there were also many improvements behind the scene.

The most important is updated code for sharing the rendered 3D scene with WinUI and Avalonia. In this case the 3D scene that is rendered by Vulkan stays in the GPU memory and is shared by the WinUI or Avalonia. The code for WinUI now uses SwapChainPanel instead of SurfaceImageSource. This is faster and better supported - SurfaceImageSource had problems on older computers or computers with integrated Intel GPU. In Avalonia the previous code for sharing texture created OpenGL vertex and pixel shaders and rendered the shared Vulkan texture to an OpenGL context. This was very complex and did not work well on all platforms. The developers of the Avalonia UI were also aware that this was not done well, so we worked together to define a new interface that can be used for sharing an external texture with Avalonia (after some private discussions with the developers the following was issued: External GPU memory interop (OpenGL, Vulkan, DirectX). The new version of the engine uses that new interface. This works very well so that shared texture can be used on computers where the previous approach did not work. What is more, Avalonia currently uses OpenGL to render its user interface, but there already exists a build of Avalonia that uses Vulkan to render the interface. This will be publicly available in one of the future versions. This means that it will be even easier and faster to share the 3D scene created with Ab4d.SharpEngine because whole application could use the same Vulkan device.

If you have not tested the beta 1 version, I would like to encourage you to try the new beta version. If you know how to create a 3D scene by using Ab3d.PowerToys, then it should be easy to work with the new library because the general concepts are the same. There are some differences in object names, but when working with the new engine, you will quickly see that the new API is much more polished than when using the Ab3d.PowerToys and Ab3d.DXEngine. The problem with those two libraries was that they were based on WPF 3D object model. That object model was extended by Ab3d.PowerToys and later by Ab3d.DXEngine objects. Because of this in those two libraries there exists multiple ways to define 3D objects: based on GeometryModel3D, Visual3D and on SceneNodes from DXEngine. Now, the 3D objects are all derived from SceneNode. All object grouping is done by GroupNode (instead of Model3DGroup, ModelVisual3D, ContentVisual3D, SceneNode). Also, when using Ab4d.DXEngine you need to use some tricks (using SetDXAttribute method) to define advanced properties on WPF materials. Now all material properties are directly accessible.

As promised before, the work on Ab3d.PowerToys and Ab3d.DXEngine will not stop. There are already many improvements and fixes in the current development version. Now I will focus on providing some additional new features and then prepare a new release. So if you have any recommendations, it is now a great time to provide that.

Tags: , ,

SharpEngine

The first beta version of a new cross-platform rendering engine has been published

by abenedik 15. December 2022 14:03

I am really glad to inform you that the first beta version of the Ab4d.SharpEngine has been published. 

Ab4d.SharpEngine logo

Ab4d.SharpEngine is a cross-platform 3D rendering engine for desktop and mobile .Net applications.

The existing rendering engine, Ab3d.DXEngine, uses DirectX 11. Because of that, it can only be used on Windows. The new engine uses Vulkan API.  And because it is built using .NET 6, the new engine is truly cross-platform and can be used on Windows, Linux (including Raspberry PI 4), macOS, Android and iOS. 

I know that now you would want to ask me: what about web? I am monitoring the status of Blazor with WebAssembly. I think that things are developing in the right direction but currently this technology is not yet capable enough for a more complex application with 3D graphics. The main problem is that WebAssembly does not have direct access to the Canvas, so each call needs to go through java script. Because 3D rendering engine needs to execute a lot of WebGL (or WebGPU) calls, this would be very slow. Also, in my opinion web will always be slow for high end and demanding 3D graphics. Anyway, the long time plan is to also provide support for web so that the same c# code could also run in a browser.

Vulkan is also an API with very little overhead, which makes it much faster than DirectX 11. What is more, Vulkan supports all new features that are added to new graphics cards, including ray tracing. This does not mean that Ab3d.DXEngine already supports ray tracing, but it is possible to add that and other new features in the future.

Because the new rendering engine was built from the ground up, it was possible to use all the know-how and experience from Ab3d.PowerToys and Ab3d.DXEngine to make its programming API clean and very easier to use. I admit that when using Ab3d.DXEngine and Ab3d.PowerToys, the API is not very nice in all cases. The Ab3d.PowerToy was built on top of WPF 3D objects that are not very extendable, so some compromises were needed (for example, cameras are derived from FrameworkElement and not from Camera). Also, Ab3d.DXEngine converts all WPF 3D and Ab3d.PowerToys objects into its own objects. This means that the application has two versions of each object. In other cases, some tricks must be used to provide Ab3d.DXEngine features to Ab3d.PowerToys and WPF 3D objects (for example using SetDXAttribute). Therefore, having an easy-to-use API was one of the primary goals of the new engine. Please contact me if you have any recommendations or find something that bothers you. 

 

I hope that you are already excited about the new rendering engine.
In that case, just jump into the samples page on GitHub: Ab4d.SharpEngine.Samples

There you will find solutions that show how to use the Ab4d.SharpEngine with WPF, AvaloniaUI, WinUI 3, SDL, Glfw. Some samples will run only on Windows; some will also run on Linux and macOS. Some will run on Android. iOS samples are coming in the near future. I also plan to add support for WinForms and MAUI. If you know of any other well know UI framework, please let me know and I will try to provide support for that too.

Check also the readme on GitHub as it provides a lot of other information.

 

Because you are an existing user of Ab3d.PowerToys and Ab3d.DXEngine, you are probably very interested in comparing the new engine with the current libraries.

Let's start with advantages of Ab3d.DXEngine and Ab3d.PowerToys:

  • Ab3d.DXEngine and Ab3d.PowerToys are very mature products that are tested and proven in the "field" by many customers.
  • Those two libraries currently provide more features and come with more samples that can be used as code templates for your needs.
  • Ab3d.DXEngine supports multi-threading and currently provides faster 3D rendering in many use cases.
  • Ab3d.DXEngine can use software rendering when there is no graphics card present (for example in virtual machines or on a server).
  • Ab3d.DXEngine and Ab3d.PowerToys can run on older .Net versions, including .Net Framework 4.5+.

Advantages of Ab4d.SharpEngine:

  • Ab4d.SharpEngine can run on multiple platforms. You can start writing code for Windows and later simply add support for Linux, macOS, Android and iOS. Or port just a smaller part of the application to other platforms.
  • Ab4d.SharpEngine uses Vulkan API that is the most advanced graphics API. It is actively developed and gets new features as new versions of graphics cards are released. This provides options to support all current and future graphics features (for example Ray tracing - not possible with DirectX 11).
  • As mentioned before, Ab4d.SharpEngine has a very clean and easy to use programming API. 
  • Working with WPF objects is very slow (accessing DependencyProperties has a lot of overhead). Also, Ab3d.DXEngine needs to convert all WPF objects into its own objects. Working with objects in Ab4d.SharpEngine is much faster.
  • Vulkan is a significantly faster graphics API than DirectX 11. Though the Ab4d.SharpEngine does not use all the fastest algorithms yet (no multi-threading), in the future the engine will be significantly faster than Ab3d.DXEngine.
  • Ab4d.SharpEngine is built on top of .NET 6 and that provides many performance benefits because of using System.Numerics, Span and other improved .NET features.
  • In the future Ab4d.SharpEngine will provide more functionality than Ab3d.DXEngine with Ab3d.PowerToys.

 

So, if you have a big and complex application that uses Ab3d.PowerToys and Ab3d.DXEngine, I would not recommend you to try to port it to the new engine. You could not just copy and paste the code to the new engine. Though the ideas and principles of both engines are still the same, for example there are TargetPositionCamera and MouseCameraController - both with almost the same properties and methods. But there are many smaller differences, for example BoxVisual3D is now BoxModelNode. Anyway, if you know how to use the existing engine, you will feel very familiar with the new engine also.

But if you are starting to build a new application with 3D graphics or would like to port some smaller part of your big application (for example a viewer with a few additional functionalities) to a more mobile format, then the new engine is a perfect choice for that. Also, if you are curious about how to program in .NET for other platforms or will have a little bit more time in December, I would be really glad if you could try the new engine and provide some feedback (you can also use Discussions or Issues on GitHub, or simply use email, forum or feedback form).

But please don't be too demanding. This is the first open beta and some things may not work as expected. In those cases, please see the Troubleshooting section on GitHub for more info.

 

Let me also share the planned road map for the new engine.

In the following weeks and months I will try to release new beta versions with fixes and improvements. After a few months, probably in Q2 or maybe in Q3 2023, the first production-ready versions should be released. Maybe some parts of the engine will remain in beta, for example AvaloniaUI, MAUI, macOS and iOS support. The plan is to have the main and most common parts ready for production: Windows (WPF, WinForms, SDL, Glfw), major Linux distributions (SDL, Glfw) and Android. 

 

And finally, I would like to assure you that Ab3d.PowerToys and Ab3d.DXEngine will still be actively developed, will get new releases and features and will have full support in the future!

 

I hope that the new engine will allow developers to use the beautiful c# language to create amazing apps with 3D graphics that could run on all possible platforms. If you have the right tools, then even 3D graphics is not hard!

And of course: Merry Christmas and happy new year!

Tags: , ,

Ab3d.PowerToys | DXEngine | SharpEngine

New versions of 3D libraries released

by abenedik 28. April 2022 19:57

I am happy to inform you that new versions of Ab3d.PowerToys and Ab3d.DXEngine libraries have been published.

This is a maintenance release with many improvements, fixes, and some new features.

The most interesting new feature in the Ab3d.DXEngine is added support for XRayEffect. The XRayEffect can render objects that look as they would be photographed by an x-ray. This can be useful when you work on a complex model with many parts and want to select one part while the other parts are just barely visible. In that case it is possible to make other parts semi-transparent. Another option that is available with the new version is to use the new XRayEffect or XRayMaterial. This works especially well when showing models with many triangles and with curved shapes. See example (this is a screenshot from slightly modified XRayEffect sample):

X-Ray effect on Ab3d.DXEngine

The new XRayEffect can be also used in the updated "Model Viewer" sample in the Ab3d.DXEngine samples (to use it check the new "Use X-Ray material" CheckBox in the second tab).

Another new feature can be used by those who use object instancing to render thousands of objects and want to do fast hit testing on the instanced objects. In this case, the new version allows rendering instance id bitmap from instanced objects. This generates a bitmap where colors represent the ids of the instances. By checking the color at a specific pixel, you can get the instance id that was rendered at that screen coordinates. This can also be used to do a rectangular selection or selection of the instance around the mouse cursor.

Also, the standard RenderToBitmap method got an improvement. With the new version it is possible to get direct access to the memory of the rendered bitmap. This way you can reuse the WritableBitmap or use any other method of using the rendered image. This is very useful when you are calling RenderToBitmap method very often because you can optimize and reuse the used objects (before a new WritableBitmap object was created on each call of RenderToBitmap method and this could generate many objects on the large memory heap).

The new version also improves stability in case of disconnecting an external monitor. Stability is also improved in some cases when rendering through a remote desktop.

The previous version introduced two-sided material that doubles the performance of rendering models that had the same front and back side materials. But this did not work in all the cases. This version fixes this issue.

There are also some other fixes and improvements. See the full list here: https://www.ab4d.com/DXEngine-history.aspx

 

The Ab3d.PowerToys library also got a few new features and improvements.

One interesting new feature is an improved algorithm for extruding a shape along a path. Now you can use two new options. One is to preserve the size of the shape at junctions and the other is to preserve the orientation of the shape's Y direction. See screenshot (the right side shows the extruded model using the new option):

Extrude a shape along a path

The new version of the library also comes with an updated Assimp importer and exporter. It now supports reading embedded textures and saving textures into fbx and glft files. There is also a new native Assimp library v5.2.3 that should improve the accuracy of importing and exporting files (https://github.com/assimp/assimp/releases/tag/v5.2.3)

To see the full list of changes see the change log here: https://www.ab4d.com/PowerToys-history.aspx

 

You can get the new version by updating the NuGet packages or by downloading the new evaluation or commercial version from your User Account web page. Note if you are using libraries from NuGet and you have recently renewed the updated subscription, then you will probably need to generate a new license activation code for the new version to work (this code can be generated from your User Account web page).

 

The list of new features is not as long as with some previous versions. The reason for this is that a lot of development effort is now spent on the new Vulkan based rendering engine (Ab3d.SharpEngine). This new engine is progressing very well. This engine will be fully cross-platform so the same code should be able to run on many different hardware devices. Recently we were able to run the code that works on Windows and desktop Linux on Raspberry Pi with a small touch screen attached - see photo:

SharpEngine on Resberry Pi with touch screen (pre-alpha)

Such a setup makes the engine great for controlling some industry machines or equipment.

The engine can also work on Android:

SharpEngine on Android phone (pre-alpha)

Many features from Ab3d.PowerToys and Ab3d.DXEngine were already ported to the new engine. But before releasing an alpha version, the core of the engine still needs some polishing and testing. I expect that the first alpha can be released in a month or two. The plan is to release a closed alpha version and later an open beta version. If you are interested in trying the new engine, please write me an email or feedback and you will be informed when the alpha version is available. This will allow you to test the engine on your hardware and on your devices. It will aso give you some influence on which features will make it to the first official and production-ready version.

Tags: , , , , , ,

Ab3d.PowerToys | DXEngine | SharpEngine