Skip to content

feat(cursor): apply texture from config for obj and stl models#119

Open
onuralpszr wants to merge 1 commit into
orhun:mainfrom
onuralpszr:feat/cursor-texture
Open

feat(cursor): apply texture from config for obj and stl models#119
onuralpszr wants to merge 1 commit into
orhun:mainfrom
onuralpszr:feat/cursor-texture

Conversation

@onuralpszr

@onuralpszr onuralpszr commented Jun 30, 2026

Copy link
Copy Markdown

This adds a texture option to the cursor model config so a base-color texture can be applied to the cursor model without editing code. Addresses #78.

[cursor.model]
path = "CairoSpinyMouse.obj"
texture = "texture.png"

The path is resolved relative to the config file, the same way path is.

  • config: new texture: Option<PathBuf> field on [cursor.model], resolved relative to the config file.
  • model: decode the image and set it as base_color_texture on the cursor material. Also load UV coordinates from OBJ files, which were previously dropped (a texture has nothing to map to without UVs).
  • systems: thread the image asset store into cursor spawning.
  • config/ratty.toml: documented example.

Signed-off-by: Onuralp SEZER <thunderbirdtr@gmail.com>
@onuralpszr onuralpszr force-pushed the feat/cursor-texture branch from d4b9412 to d315cd3 Compare June 30, 2026 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant