Releases: renatillas/tiramisu
Releases · renatillas/tiramisu
Release list
v8.0.0
v7.0.0
v7.0.0-rc1
Gleam v7.0.0-rc1
v4.1.0
Added
- Spritesheet Animation System: Complete texture-based sprite animation support
spritesheet.from_grid()- Create spritesheets from grid-based texture atlasesspritesheet.animation()- Define animation sequences with frame indices and timing- Three loop modes:
Once,Repeat, andPingPongfor different animation behaviors scene.animated_sprite()- Scene node for displaying animated sprites- Animation state control: play, pause, stop, and change animations dynamically
- Pixel art support with
NearestFilterfor crisp, non-blurred sprites - Independent animation per sprite instance (automatic texture cloning)
- Example:
examples/27-spritesheet_animationdemonstrates three independently animating coins
- Texture Manipulation API: New utilities for advanced texture control
texture.clone()- Clone textures for independent manipulationtexture.set_offset()- Control UV offset for texture positioningtexture.set_repeat()- Control UV repeat/scalingtexture.set_wrap_mode()- Set texture wrapping behavior (Repeat, Clamp, MirroredRepeat)texture.set_filter_mode()- Set texture filtering (Nearest for pixel art, Linear for smooth)
- 3D Sprite Labels with Canvas Rendering: New sprite system for depth-aware labels that properly occlude behind 3D objects
scene.canvas()- Create canvas-based sprites withpaint.Picturefor drawing custom graphics- Sprites use canvas 2D rendering via the
paintlibrary for flexible visual customization - True 3D depth testing - sprites hide behind other objects in the scene
- Perfect for health bars, damage numbers, interactive labels, and UI elements in 3D space
- Example:
examples/26-css2d_labelsdemonstrates sprite usage alongside CSS2D labels
- CSS2D and CSS3D Label Support: HTML-based overlay labels for UI elements
scene.css2d_label()- Create screen-space HTML labels that always render on topscene.css3d_label()- Create 3D-positioned HTML labels (no depth occlusion with WebGL)- Full HTML/CSS support with Tailwind styling
- Useful for UI overlays, tooltips, and text that should never be occluded
- Paint Library Integration: Added
paint(v0.4.0) dependency for canvas-based drawing- Functional canvas 2D API for creating Pictures
- Combines shapes, text, fills, strokes with composition
- Pictures are rendered to canvas textures for sprite display
v4.0.2
CHANGELOG
Fixed
- Orthographic camera resize handling: Fixed window resize listener to properly update orthographic cameras
- Resize event now updates orthographic camera frustum (left, right, top, bottom) based on new window dimensions
- Previously only perspective cameras were updated on resize, causing 2D games to stretch when window was resized
camera_2d()cameras now maintain correct aspect ratio and scale across all window sizes
v4.0.1
Changelog
Fixed
- Production build compatibility: Fixed constructor name encoding issues that could cause failures in minified builds
- Background type checking now uses Gleam-generated
Background$is*functions instead ofconstructor.name - Asset type checking now uses Gleam-generated
AssetType$is*functions instead ofconstructor.name - ID serialization now uses WeakMap-based stable constructor IDs instead of
constructor.name - All FFI code is now immune to JavaScript minification and build optimization
- Background type checking now uses Gleam-generated
v4.0.0
Changelog
Added
- Comprehensive API documentation: Added extensive module-level and function-level documentation with examples for:
scenemodule - Scene node system with constructor functions, node types, and usage patternsanimationmodule - Tweening and model animation systemphysicsmodule - Rigid body dynamics, colliders, forces, and collision detectionmaterialmodule - PBR materials, builder pattern, texture mapping exampleslightmodule - Lighting types, shadow configuration, typical setupsdebugmodule - Debug visualization utilities and performance monitoringstate_machinemodule - Type-safe animation state machines with contextparticle_emittermodule - GPU-accelerated particle effects with builder APIaudiomodule - Spatial and global audio with Web Audio APIassetmodule - Asset loading, caching, and batch loadingspatialmodule - Spatial partitioning and collision detection
- Scene node constructor functions: Scene nodes now use opaque types with explicit constructor functions:
scene.mesh()- Create mesh nodesscene.instanced_mesh()- Create instanced mesh nodesscene.group()- Create group nodesscene.light()- Create light nodesscene.camera()- Create camera nodesscene.lod()- Create LOD nodesscene.model3d()- Create 3D model nodesscene.instanced_model()- Create instanced model nodesscene.audio()- Create audio nodesscene.particles()- Create particle emitter nodesscene.debug_*()- Create debug visualization nodes
- Enhanced Collider API: Spatial module now uses a unified
Collidertype supporting both boxes and spheres:spatial.collider_box()- Create box collider from min/max pointsspatial.collider_box_from_center()- Create box from center and half-extentsspatial.collider_sphere()- Create sphere collider from center and radiusspatial.collider_contains_point()- Point-in-collider test (works for both box and sphere)spatial.collider_intersects()- Collider intersection test (box-box, sphere-sphere, box-sphere)- Box-sphere collision detection for heterogeneous spatial queries
- Documentation guide: Added
docs/physics-guide.mdwith comprehensive physics system documentation
Changed
- Scene module refactoring: Moved renderer logic from
tiramisu/internal/renderer.gleamintotiramisu/scene.gleamfor better organization (removed 1926 lines, added rendering functions directly to scene module) - Scene.Node type is now opaque: Must use constructor functions instead of direct constructors (e.g.,
scene.mesh()instead ofscene.Mesh()) - Spatial API redesign: Renamed
AABBtype toColliderand updated all related functions:spatial.aabb()→spatial.collider_box()spatial.aabb_from_center()→spatial.collider_box_from_center()spatial.aabb_contains_point()→spatial.collider_contains_point()spatial.aabb_intersects()→spatial.collider_intersects()spatial.aabb_center()→spatial.collider_center()- Octree API updated to use new collider types:
octree_new(),octree_insert(),octree_query_radius(), etc.
- Type reorganization:
- Moved
Object3Dtype fromtiramisu/object3dmodule totiramisu/assetmodule - Moved
AnimationCliptype fromtiramisu/object3dmodule totiramisu/animationmodule - Moved
AnimationPlaybacktype totiramisu/animationmodule
- Moved
- Context type simplified: Removed
input_managerfield fromContexttype (internal implementation detail) - Main module streamlined: Simplified
tiramisu.gleamby removing example code and focusing on core API surface - Documentation improvements: Updated scene graph and getting started guides, removed spatial partitioning guide (content integrated into API docs)
v3.0.0
- The
WorldConfig's parametercorrespondenceshas been removed from the physics module. - The function
step_worldfrom the module physics has been removed in favour of thestepfunction. - Fixed references to tiramisu.Color and tiramisu.Texture, as they should be background.Color and background.Texture.
- The
RigidBodytype from the physics module is now opaque - The
Transformtype is now opaque - fields cannot be accessed directly - Direct field access (e.g.,
transform.position) must be replaced with accessor functions - The
Quaterniontype has been moved from thephysicsmodule to thetransformmodule - Added
transform.position(t)- Get position from a transform - Added
transform.rotation(t)- Get rotation as Euler angles (radians) - Added
transform.rotation_quaternion(t)- Get rotation as a quaternion - Added
transform.scale(t)- Get scale from a transform - Added
transform.with_euler_rotation(t, euler)- Set rotation using Euler angles - Added
transform.with_quaternion_rotation(t, quat)- Set rotation using a quaternion - Added
transform.with_rotation(t, euler)- Alias forwith_euler_rotation(backwards compatible) - Added
transform.euler_to_quaternion(euler)- Convert Euler angles to quaternion - Added
transform.quaternion_to_euler(quat)- Convert quaternion to Euler angles - Added
transform.identity_quaternion- The identity quaternion (no rotation) - Rotations are now stored internally as quaternions to avoid gimbal lock
rotate_by()now uses proper quaternion multiplication for accurate rotation composition- All quaternion/Euler conversions implemented in pure Gleam (no FFI)
- Smoother rotation interpolation with spherical linear interpolation (slerp)