Returns the minimum Y coordinate of a mesh's bounding box in local mesh space.
Takes entity (mesh entity handle).
Returns minimum Y value, or 0.0 on error.
3D Graphics
Parameters & Returns
Parameters
entityInt
Returns
Double
Quick Summary
Returns the minimum Y coordinate of a mesh's bounding box in local mesh space.
Takes entity (mesh entity handle).
Returns minimum Y value, or 0.0 on error.
Technical Exegesis...
Returns the minimum Y coordinate of a mesh's bounding box in local mesh space. Takes entity (mesh entity handle). Returns minimum Y value (Double), or 0.0 on error. Validates entity exists and type is ENTITY_MESH. Validates mesh has vertex data (not empty). Iterates all vertices in mesh to find minimum Y position. Returns unscaled mesh-space coordinate (does not account for entity scale/rotation). Silently returns 0.0 on errors.
Returns the minimum Y coordinate of a mesh's bounding box in local mesh space. Takes entity (mesh entity handle). Returns minimum Y value (Double), or 0.0 on error. Validates entity exists and type is ENTITY_MESH. Validates mesh has vertex data (not empty). Iterates all vertices in mesh to find minimum Y position. Returns unscaled mesh-space coordinate (does not account for entity scale/rotation). Silently returns 0.0 on errors.
This function queries mesh bounding box extent for collision detection, ground placement, or procedural stacking. Returns local-space coordinates before transforms applied - multiply by entity scale to get world-space extent. Useful for: (1) Ground placement (place mesh on ground: entityY = groundY - b3dMeshMinY), (2) Vertical stacking (stack objects: nextY = prevY + b3dMeshMaxY(prev) - b3dMeshMinY(next)), (3) Calculating height (height = MaxY - MinY), (4) Collision volume sizing. Coordinate system: right-handed, Y-axis points up. For scaled bounds, multiply by b3dEntityScaleY (global scale). For rotated bounds, transformation required (not axis-aligned). Complements b3dMeshHeight (height = MaxY - MinY), b3dMeshWidth, b3dMeshDepth. Use b3dFitMesh to scale mesh to fit target dimensions. Returns actual vertex position min - for primitives like sphere/cube, typically -radius or -size/2. For loaded meshes, depends on modeling coordinates (Y-up vs Z-up). Common values: cube (-1.0), sphere (-1.0), custom meshes (arbitrary). Performance: O(n) iteration over vertices - cache result if querying repeatedly. Does not trigger GPU operations.
Example
Example.bam
; Place mesh with bottom at ground level (Y=0)Local mesh:Int = b3dCreateCube(1, 0, 0)
Local minY:Double = b3dMeshMinY(mesh)
b3dPositionEntity(mesh, 0, -minY, 0) ; Bottom edge at Y=0