slint-ui/slint · error

the renderer-software feature must be enabled in i-slint-com

Error message

the renderer-software feature must be enabled in i-slint-compiler when embedding textures

What it means

Error "the renderer-software feature must be enabled in i-slint-compiler when embedding textures" thrown in slint-ui/slint.

Source

Thrown at internal/compiler/lib.rs:224

    /// Set automatically when the output format is `SlintSc`.
    /// The compiler rejects all features not supported by the
    /// safety-critical subset.
    #[cfg(feature = "slint-sc")]
    pub(crate) slint_sc: bool,

    /// Set by tools such as `slint-viewer`, the LSP (editor diagnostics/preview), and the
    /// live-reload runtime to indicate that the `.slint` file is being previewed rather than
    /// driven by real host application logic.
    pub is_preview: bool,
}

impl CompilerConfiguration {
    pub fn new(output_format: OutputFormat) -> Self {
        let embed_resources = if std::env::var_os("SLINT_EMBED_TEXTURES").is_some()
            || std::env::var_os("DEP_MCU_BOARD_SUPPORT_MCU_EMBED_TEXTURES").is_some()
        {
            #[cfg(not(feature = "renderer-software"))]
            panic!(
                "the renderer-software feature must be enabled in i-slint-compiler when embedding textures"
            );
            #[cfg(feature = "renderer-software")]
            EmbedResourcesKind::EmbedTextures
        } else if let Ok(var) = std::env::var("SLINT_EMBED_RESOURCES") {
            let var = var.parse::<bool>().unwrap_or_else(|_|{
                panic!("SLINT_EMBED_RESOURCES has incorrect value. Must be either unset, 'true' or 'false'")
            });
            match var {
                true => EmbedResourcesKind::EmbedAllResources,
                false => EmbedResourcesKind::OnlyBuiltinResources,
            }
        } else {
            match output_format {
                #[cfg(feature = "rust")]
                OutputFormat::Rust => EmbedResourcesKind::EmbedAllResources,
                OutputFormat::Interpreter => EmbedResourcesKind::Nothing,
                _ => EmbedResourcesKind::OnlyBuiltinResources,

View on GitHub (pinned to 3fd8f2ec03)

Solutions

  1. Enable the renderer-software feature of i-slint-compiler when using texture embedding.
  2. Unset SLINT_EMBED_RESOURCES or disable texture embedding.

When it happens

Trigger: Thrown at internal/compiler/lib.rs:224 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of slint-ui/slint@3fd8f2ec03 (2026-08-19). Data as JSON: /api/errors/0eebcad3fb810047. Report an issue: GitHub.