v5.5.3
·
39 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
Doc improvements and bug fixes ported from upstream raylib-rs, scoped to
soundness and correctness. Thanks to all the original authors linked below.
Breaking
Image::export_image_to_memorynow returnsResult<Vec<u8>, Error>instead
ofResult<&[u8], Error>. The previous signature leaked on every call
(raylib's buffer was never freed) and had an unsound lifetime. Adapted from
raylib-rs #250 / #247.
Deprecated
RaylibMesh::indicies/indicies_mut— useindices/indices_mut. The
typo'd names stay through 5.x and are removed in 6.0.
Fixed
- Soundness:
RaylibMeshaccessors return an empty slice when the
underlying buffer is null instead of invoking UB via
slice::from_raw_parts(null, _)(raylib-rs#257). - Soundness:
RaylibMesh::indiceslength is nowtriangleCount * 3(what
raylib allocates) rather thanvertexCount(raylib-rs#257). - Soundness:
Sound::aliaslifetimes correctly bind the sound's lifetime to
the receiver (4d53bd4). - Use-after-free:
load_model_animationsfrees only the outer array via
MemFree, rather thanUnloadModelAnimationswhich also tore down the
animations theVechad just taken ownership of (ccc0827). - Data corruption:
AudioStream::updatepasses element count (not byte
size) toffi::UpdateAudioStream, matching the C API
(raylib-rs#212). Texture2D::update_texture_recvalidates the destination rectangle and sizes
the expected pixel buffer from rect dimensions (cb0c004).- Closure-based draw helpers (
draw,draw_mode2D, etc.) no longer call
ffi::End*()twice — the handle'sDropalready does
(aadf1a7). gui_text_boxandgui_text_input_boxgrow the buffer and round-trip the
null terminator, so text input works (e2be94b).gui_panelpasses a null pointer for empty strings, matchingGuiPanel's C
API (95234d1).
Other
- Add docs to README on drop ordering.
- CI and
just okbuild with--all-targetsso examples are exercised
alongside the library crates. - Examples look better on High DPI screens.
just examplesto quickly run a bunch of different examples.