Skip to main content

SDL_GetProcessInput

Function SDL_GetProcessInput 

Source
pub unsafe extern "C" fn SDL_GetProcessInput(
    process: *mut SDL_Process,
) -> *mut SDL_IOStream
Expand description

Get the SDL_IOStream associated with process standard input.

The process must have been created with SDL_CreateProcess() and pipe_stdio set to true, or with SDL_CreateProcessWithProperties() and SDL_PROP_PROCESS_CREATE_STDIN_NUMBER set to SDL_PROCESS_STDIO_APP.

Writing to this stream can return less data than expected if the process hasn’t read its input. It may be blocked waiting for its output to be read, if so you may need to call SDL_GetProcessOutput() and read the output in parallel with writing input.

Parameter: process The process to get the input stream for. Returns: the input stream or NULL on failure; call SDL_GetError() for more information.

Thread Safety: It is safe to call this function from any thread.

Available Since: This function is available since SDL 3.2.0.

See Also: SDL_CreateProcess See Also: SDL_CreateProcessWithProperties See Also: SDL_GetProcessOutput