Click or drag to resize
Ab4d.SharpEngine logo

Ab4d.SharpEngine.Utilities Namespace

 
Classes
 ClassDescription
Public classBezierCurve BezierCurve class is used to create a 3D Bezier curve.
Public classBitmapFont BitmapFont class defines a font that is created by a bitmap with rendered characters and font data that define where on the bitmap each character is. This class can read bitmap font from binary data (usually form .fnt files). The created BitmapFont can be used by the BitmapTextCreator. To use the build-in default font call the GetDefaultBitmapTextCreator(Scene) method. See remarks for the BitmapTextCreator for more information on how to generate bitmap font files.
Public classBitmapFontCharacter 
Public classBitmapTextCreator BitmapTextCreator class can be used to generate SceneNodes that show text by using bitmap fonts. Bitmap font is defined by one or more textures with rendered characters and font data that define where on the texture the character is. The binary font data can be created by a third party "Bitmap Font Generator" (for example from https://www.angelcode.com/products/bmfont/). To use the build-in default font call the GetDefaultBitmapTextCreator(Scene) method. See remarks for more information on how to generate bitmap font files.
Public classBSpline BSpline class is used to create a 3D B-spline.
Public classCameraController CameraController is an abstract class that provides the basic code for camera controller for camera rotation, movement and quick zoom. Usually this class is first used by the ManualPointerCameraController and that is used by the platform specific PointerCameraController that is defined in per-platform assembly (for example Ab4d.SharpEngine.Wpf, Ab4d.SharpEngine.WinUI, Ab4d.SharpEngine.AvaloniaUI).
Public classCameraUtils CameraUtils class contains some helper methods to work with cameras.
Public classCommonStatesManager CommonStatesManager defines the common GPU states.
Public classConditionalLogger ConditionalLogger has Write methods available only when compiled with FULL_LOGGING constant
Public classDisposeList DisposeList contains a list of IDisposable objects that are automatically disposed when DisposeList is disposed. The order of disposal is reversed from the order in which the objects were added to the list (first object is disposed last).
Public classDynamicMemoryBlockT DynamicMemoryBlock creates an array of T structs that can be accessed with the Data field. It provides GetNextFreeIndex method to get index of next free item in the Data array (this method sets the returned index as used). The FreeIndex(Int32) method frees the specified index. The class is using a very memory efficient bits from an array of ulong values to mark which elements in the Data array are used and which are free.
Public classEdgeLinesFactory EdgeLinesFactory can generated edge lines where the angle between two adjacent triangles is bigger then the specified angle.
Public classEffectsManager EffectsManager class help use the Effect classes. It provides loading, caching and reusing the effects and shaders. All access to effects and shaders is thread safe.
Public classFileUtils FileUtils static class contains method that help working with files.
Public classGpuDynamicMemoryBlockT 
Public classGpuDynamicMemoryBlockPoolT 
Public classGpuSamplerManager GpuSamplerManager can be used to get the common textures samplers or create a custom sampler. Sampler defines how the texture bitmap is read by the GPU. The default sampler in SharpEngine is MirrorSampler.
Public classGpuVertexBufferDescriptionsManager 
Public classHeapAllocator 
Public classHitTester HitTester is a class that can be used do a hit testing on a mesh data with vertex and index buffer. The static methods in this class take a Ray, various types of vertex buffers, index buffer and a few flags and returns a hit test result.
Public classInputEventsSource Base class for all InputEventsSource classes that are used by the ManualInputEventsManager.
Public classLicenseLogger LicenseLogger has Write methods available only when compiled with LICENSE_LOGGING constant. It always writes log messages with License log level.
Public classLineSelectorData LineSelectorData class can be used to get the closest line to the pointer or mouse position. It also gets the distance to the specified view position and the line segment index. Before getting the closets distance by calling the GetClosestDistance(Vector2, Single) or GetClosestPositionOnLine(Vector3, Vector3), the CalculateViewPositions or [!:CalculateViewPositions(Matrix4x4, float, float)] method must be called.
Public classLineUtils LineUtils class defines static methods that can be used to create wireframe lines, normal lines and edge lines.
Public classLog 
Public classManualInputEventsManager ManualInputEventsManager class simplifies working with pointer and mouse events on 3D objects. Because this class is cross-platform, it cannot subscribe to platform specific events. This is done in special InputEventsManager classes that are implemented for WPF, Avalonia, WinUI and WinForms. The following events can be subscribed on 3D objects: PointerPressed, PointerReleased, PointerClicked, PointerDoubleClicked, PointerWheelChanged, PointerEntered, PointerExited, PointerMoved, BeginPointerDrag, PointerDrag and EndPointerDrag events. To register for those events, create an instance ModelNodeEventsSource, NamedModelNodesEventsSource, NamedModelNodesEventsSource or created your own class that is derived from InputEventsSource. ManualInputEventsManager also provides a generic PointerEntered, PointerExited, PointerPressed, PointerReleased and PointerMoved events that can be used to be notified when a button is pressed or released over the SceneView or when pointer or mouse is moved.
Public classManualMouseCameraControllerObsolete.
ManualMouseCameraController is obsolete. Please use ManualPointerCameraController instead.
Public classManualPointerCameraController ManualPointerCameraController is a camera controller that can control the camera by pointer or mouse events. Because ManualPointerCameraController is cross-platform it does not provide any actual pointer or mouse binding. Therefore, user must manually call ProcessPointerPressed(Vector2, PointerButtons, KeyboardModifiers), ProcessPointerReleased(PointerButtons, KeyboardModifiers), ProcessPointerMoved(Vector2, PointerButtons, KeyboardModifiers) and ProcessPointerWheelChanged(Vector2, Single) methods.
Public classMathUtils MathUtils is a static class with math utility methods that can be used for 3D graphics.
Public classMemoryUtils MemoryUtils is a static class that contains methods and property that can be used to perform advanced memory copy operations by using AVX2 NonTemporal instructions. Do disable AVX2 NonTemporal, set the static UseAdvancedMemoryCopyInstructions to false.
Public classMeshAnalyzer MeshAnalyzer class can analyze the mesh and produce a list of Edges and Polygons (triangles) that define the mesh. MeshAnalyzer can also create edge lines that are created between triangles that have normal angles bigger than the specified angle.
Public classMeshBooleanOperations MeshBooleanOperations static class defines methods that can execute subtract, intersect or union operations on 3D models.
Public classMeshUtils MeshUtils provides static helper methods for working with 3D meshes.
Public classModelMover ModelMover is a helper class that can be used to move selected 3D models in the 3D space. Its ModelMoverGroupNode can show 3 arrows and 3 planes that can be dragged by the user.
Public classModelNodeEventsSource ModelNodeEventsSource class is used to register a ModelNode object to the InputEventsManager.
Public classModelRotator ModelRotator is a helper class that can be used to rotate selected 3D models in the 3D space. Its ModelRotatorGroupNode can show 3 circles that can be dragged by the user to rotate the selected 3D model.
Public classModelScalar ModelScalar is a helper class that can be used to scale selected 3D models. Its ModelScalarGroupNode can show 3 axes with box and a center box that can be dragged by the user.
Public classModelUtils ModelUtils class contains static methods that can process ModelNode objects that are children of a GroupNode.
Public classMultiModelNodesEventsSource MultiModelNodesEventsSource class is used to register multiple ModelNode object to the InputEventsManager.
Public classNamedModelNodesEventsSource NamedModelNodesEventsSource class is used to register ModelNode objects by their name. It is also possible to use wildcard name that is defined when the name starts with * or end with *. For example, "Box*" matches all ModelNodes whose name start with "Box"; "*_blue" matches all ModelNodes whose name ends with "_blue".
Public classObjectPoolT Dynamic object pool that allocate new instance when necessary.
Public classPlanarShadowMeshCreator PlanarShadowMeshCreator is a class that can be used to create a planar shadow mesh. This is a mesh that is created by squishing the SceneNodes specified in the OriginalGroupNode to the specified plane. The squished mesh has zero height. The mesh can be used to create MeshModelNode that shows the shadow.
Public classPngBitmapIO PngBitmapIO is a build-in png reader and writer and implement bitmap IO operations that are defined in IBitmapIO interface.
Public classReaderObj ReaderObj can read 3D models from obj files.
Public classResourceTracker ResourceTracker collects classes that implement ComponentBase and can report all created objects. Objects are collected with WeakReference. Resource tracker is also used to get the next object id by calling its GetNextId(IComponentBase) method.
Public classShadersManager ShadersManager provides methods for loading and caching shaders (vertex, geometry, fragment shaders).
Public classSpriteBatch SpriteBatch class defines a collection of sprites (textures) or texts that can be very quickly rendered to the 3D scene. SpriteBatch objects can be created by calling Scene.CreateBackgroundSpriteBatch(String), Scene.CreateOverlaySpriteBatch(String), SceneView.CreateBackgroundSpriteBatch(String) or SceneView.CreateOverlaySpriteBatch(String). When the SpriteBatch is created from SceneView, then it can use absolute coordinates when calling Draw methods.
Public classStandardLogger 
Public classTextBlockFactory TextBlockFactory is a helper class that can create text blocks with specified background and border. The TextBlockFactory can use the default SharpEngine's BitmapTextCreator (created by GetDefaultBitmapTextCreator(Scene)) or can be created by a custom BitmapTextCreator.
Public classTextureFactory TextureFactory is a static helper class that defines methods to create textures.
Public classTextureLoader TextureLoader is a static helper class that can be used to create a texture (as GpuImage) from a file. The file can be loaded by providing the file name or the file stream. The texture (GpuImage) can be created by calling CreateTexture method. The created texture can also be cached by the Scene or GpuDevice. Also, before loading the file, the Scene or GpuDevice cache can be checked if the file was already loaded. See remarks for more info.
Public classTransformationUtils TransformationUtils is a static helper class that defines method that helps working with transformations.
Public classTriangulator Triangulator can be used to convert one or more polygons that are defined by a list of 2D points into triangles (triangle indices).
Public classVertexBufferDescription 
Public classVulkanDebugUtils 
Public classVulkanDescriptorSetFactory 
Public classVulkanMemoryAllocator 
Public classVulkanSharedTextureHelper 
Structures
 StructureDescription
Public structureBitmapFontCharPadding 
Public structureBitmapFontKerning 
Public structureBitmapFontPage 
Public structureGradientStop Describes the location and color of a transition point in a gradient.
Public structureMeshEdge MeshEdge defines an edge in a 3D mesh. The edge is defined by StartPositionIndex and EndPositionIndex that represents two indexes in the mesh's positions collection. MeshEdge also defines indexes of polygons that use that edge.
Public structureMeshPolygon MeshPolygon defines a polygon in a 3D mesh. Polygon is a collection of edges that lie on the same 3D plane. Because orientation of edges is important because it defines the front and back face, the MeshPolygon also defines the IsEdgeFlipped that specifies if edge is flipped (start and end are flipped).
Delegates
 DelegateDescription
Public delegateModelMoverModelMovedEventHandler ModelMovedEventHandler
Public delegateModelRotatorModelRotatedEventHandler ModelRotatedEventHandler
Public delegateModelScalarModelScaledEventHandler ModelScaledEventHandler
Enumerations
 EnumerationDescription
Public enumerationMathUtilsPlaneIntersectionType PlaneIntersectionType enum defines types of intersections with the plane that can be get with GetIntersectionType methods.