Repository navigation
v0.2.0
Breaking
- lactea:
Engine::newreturnsResult<Engine, EngineError>(it sanitises the config: mesh clamp, size and fps of at least 1);Engine::resizereturnsResult<(), EngineError>andEngine::set_mesh_sizeResult<[u32; 2], EngineError>, both keep the old size on failure - lactea-render:
Renderer::new,resizeandset_mesh_sizereturnRenderError::Invalidfor a size beyond the device'smax_texture_dimension_2dor a mesh beyond 300 cells - lactea-render:
noise::generateandgen_noise_voltake&CompatRules;CompatRulesgainsmax_rand_slot,rand_filter_raw_name,noisevol_row_stride,shader_time_wrap,md2_shader_inputs,md2_input_vars(the struct is#[non_exhaustive]) - lactea-capi:
LacteaCompatis anint32_twithLACTEA_COMPAT_{PROJECTM,MILKDROP2,MILKDROP3,AUTO}constants instead of an enum; an unknown value makeslactea_createreturn NULL;lactea_set_fps(0)and a non-finitepreset_durationareInvalidArgument - lactea-preset:
ParseErrorgainsTooLarge,BinaryDataandNoKeys;Flavor::ProjectMnow rejects presets over 1 MiB, with a NUL byte, or without a key line, like projectM (the MilkDrop 2 flavour is unchanged) - lactea-jpeg: the
imagefallback for JPEGs stb rejects is gone (thejpegfeature of the C API and the CLI is removed); such files now fail to decode, as in projectM - lactea-hlsl:
Optionsgainsrand_max_slotandrand_strict_name - lactea-render, lactea-app, lactea-capi: wgpu is built without default features (
std,parking_lot,wgslplus one backend per platform); the OpenGL ES / WebGL backend is the opt-inglesfeature oflactea-render,lactea-appandlactea-capi - lactea-abi:
serdeis an optional feature (enabled bylactea-cliandlactea-compare) - web example:
resize()returnsResult<(), JsValue>
Added
- sprites: projectM user sprites:
Engine::{sprite_create, sprite_destroy, sprite_destroy_all, sprite_count, sprite_ids, set_max_sprites, max_sprites, sprite_var, set_sprite_var},lactea_preset::parse_user_spriteand the C APIlactea_sprite_*; during a soft cut they are drawn after the blend onto the output andburngoes into both presets - playlist:
lactea_playlist_*, a C API for everyprojectm_playlist_*call (a connected playlist loads files and answers the engine's switch requests);lactea_host::PlaylistFs::{add_path, insert_path}andscan_presets,.prjmaccepted wherever presets are scanned - api:
Engine::burn_texture/lactea_burn_texture_rgba,Engine::reload_textures/lactea_reset_textures,lactea::VCS_VERSION/lactea_vcs_version,lactea_set_log_callback/lactea_set_log_level(alogfacade bridge),lactea_set_texture_load_callback - md2: BeatDrop inputs under
Compat::MilkDrop2:mousex mousey mousedown mouseclick,ctrllt ctrlrt ctrldn ctrlupandyear .. totalsecondsexpression variables, shader_c14/_c15/_c16,Engine::{set_date_time, clear_date_time, set_ctrl_keys, monitor}and their C exports, and BeatDrop's shader FFT (lactea_audio::BeatDropShaderFft,sampler_fft/sampler_wave,get_fft*,get_wave) - engine:
PresetControl::preset_duration_sampledandEngine::set_loaded_preset_duration:progressruns over the sampled display time once a host reports it (the C API and the app do) - hlsl:
wrapped_hlsl(kind, user, md3, projectm)andrand_slot - eel:
Context::try_run - host: new crate
lactea-host(directory textures with an optional decode cache, image / media / WAV decode, GPU setup, preset scanning) shared by the C API, the CLI and the app; new unpublished cratelactea-testutil(shared GPU test helpers) - render:
readback_rgba8is public
Changed
- render: projectM-flavour shaders write alpha 1.0 (
MilkdropShader.cpp:468); thenoisevol_*textures use projectM'sz * sizeslice stride (noisevol_row_stride);_c2.xis the raw time under MilkDrop 2 (projectM and MilkDrop 3 wrap it modulo 10000,shader_time_wrap) - engine: one
randNNparser for samplers andtexsize_randNN, slot range 15 (projectM) / 99 (MilkDrop 2); the pool prefix filter reads the raw sampler name in projectM mode (a quality prefix defeats it) and the peeled name in MilkDrop 2 - engine: the first rendered frame has
dt = 0;set_fps(0)is ignored; a transition of duration 0 reports progress 1 - audio: non-finite PCM samples read as 0 (MD3: ±inf saturates, NaN is 0) and a non-finite volume sensitivity is ignored
- app: the preset browser runs on
PlaylistandPresetControl(the app's Random can repeat the current preset, asPlaylist's pick does; seeded display-time draws differ from before); textures come fromlactea_host::DirTexturesin projectM scan order (directory order, then path) and.ddsfiles are indexed;--duration,--transition-durationand--duration-randmust be finite and at most 1e9 s;ResetRequiredrebuilds the audio decoder from the new default track; symphonia is built with an explicit format list - jpeg: decoding is bounded to 2 GiB, allocations are fallible, and a frame without a scan is an error
- wav: a short
fmtchunk is an error - perf: release builds use fat LTO and strip symbols and wgpu keeps one backend per platform (the
fdrenderrelease binary shrinks from 87 MB to 7.3 MB); per-frame wave, overlay, motion-vector, border and vertex buffers are reused, blit and blur bind groups are cached, and the MD3 spectrum FFT is cached - refactor:
lactea-render'srenderer.rsis split intorenderer/{mod, pipelines, uv_readback, orchestrate, passes, fixed, burn}.rs; the MD2 and MD3 blend patterns sharegen_plasma(engine/blend_patterns.rs); wave, shader-snippet and sprite-fragment helpers are shared
Fixed
- engine:
Engine::newno longer panics on a zero size or a tiny mesh (an MD2 soft cut with mesh[3, 5]used to) - eel: parse paths no longer panic;
Context::runreturns 0 for a foreign program andContext::get/set,GlobalMemory::reg/set_regignore foreign variables and out-of-range registers;megabuf/gmegabufblocks are allocated on first write - render: a zero-width
volume_alpha_modis a step, not NaN; the MD2 main wave and its raw geometry return nothing for fewer than 576 samples; the MD2 shape border gate is> 0; byte-length and read-back arithmetic usesusize/u64 - preset:
SpriteName=is read after its own key, not after the first= - capi: the read-back buffer is released on every error path; the
lactea_set_texture_dirextension list and theLacteaConfig::compatdocumentation are corrected - sprites: a user sprite over a soft cut is no longer distorted by the transition
Full changelog: CHANGELOG.md