Function SDL_memset4

pub unsafe extern "C" fn SDL_memset4(
    dst: *mut c_void,
    val: u32,
    dwords: usize,
) -> *mut c_void
Available on crate feature dep_sdl3 only.
Expand description

Initialize all 32-bit words of buffer of memory to a specific value.

This function will set a buffer of dwords Uint32 values, pointed to by dst, to the value specified in val.

Unlike SDL_memset, this sets 32-bit values, not bytes, so it’s not limited to a range of 0-255.

§Parameters

  • dst: the destination memory region. Must not be NULL.
  • val: the Uint32 value to set.
  • dwords: the number of Uint32 values to set in dst.

§Return value

Returns dst.

§Thread safety

It is safe to call this function from any thread.

§Availability

This function is available since SDL 3.2.0.