feat(@typegpu/geometry): Raycast against a mesh on the CPU
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 48/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- computer-graphics, typescript
- Área
- backend, computer-graphics
Línea de trabajo
Start with the mesh endpoint from #2997 and inspect IndexedGeometry's vertexAt(i), indexAt(i), and topology APIs. The issue proposes meshes.raycast(geometry, origin, direction) for triangle-list meshes, returning the nearest hit with barycentric data and available vertex attributes. Done means callers can raycast indexed and non-indexed geometry synchronously in local space; the back-face and all-hit questions still need decisions.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Use case: world-space UIs (https://github.com/software-mansion/typegpu-kit/issues/15). A UI is rendered to a texture on a plane, and pointer events need the hit UV. Picking on the GPU is async and has no UVs, so this needs a sync CPU raycast against the mesh.
It builds on the mesh endpoint from #2997, which already gives everything needed: vertexAt(i), indexAt(i) on IndexedGeometry, and the topology.
Proposal:
const hit = meshes.raycast(geometry, origin, direction);
// { distance, triangle, barycentric, position, normal, uv } | undefined
- Works for
triangle-listgeometry, indexed or not. - Returns the nearest hit along the ray, or
undefined. triangleandbarycentriclet you interpolate any attribute of a custom vertex schema.position,normalanduvare filled when the schema has them (the defaultVertexdoes).- The ray is in the geometry's local space. Moving it by the inverse of an instance's placement stays with the caller (or a helper in the kit).
Open questions:
- Hit back faces too, or only front faces by default? A UI plane wants both.
- One hit, or an option for all hits sorted by distance?
- No acceleration structure at first: a linear pass over the triangles is fine for UI planes and small meshes. A BVH can come later if someone raycasts big meshes every frame.
- Lenguaje dominante
- TypeScript
- Estrellas
- 3.4k
- Forks
- 151
- Merge medio
- 3 d 8 h
- PR fusionados (30 d)
- 55
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de software-mansion/TypeGPU
-
fix(unplugin-typegpu): `getLang()` misidentifies file extensions when a query contains a dotQuizá libre de nuevo Un pull request para esta issue se cerró sin fusionarse. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
software-mansion/TypeGPU#3433 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
fix(unplugin-typegpu): Return `undefined` from TypeGPU’s Bun `onLoad` when no transform is neededAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
software-mansion/TypeGPU#3429 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
chore(unplugin-typegpu): Inconsistent warning prefixes across entry pointsPosiblemente ocupada @dchaudhari7177 la tomó hace 9 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
software-mansion/TypeGPU#3418 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug: f16 writes always fail in the compiled writer on engines without DataView.setFloat16 (React Native / Hermes)Posiblemente ocupada @dchaudhari7177 la tomó hace 8 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
software-mansion/TypeGPU#3405 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
docs: Remove popups from examplesPosiblemente ocupada @aleksanderkatan la tomó hace 8 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
software-mansion/TypeGPU#3327 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 1 día
Todos los issues de software-mansion/TypeGPU
Issues similares
-
enhancement from-app needs-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
nightly-labs/openbot#19162 ·
Los mantenedores suelen responder en 1 día
-
triage:in-progress
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Cotal-AI/Cotal#11229 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
npm ci fails with EALLOWREMOTE on npm 12Posiblemente ocupada @landry-kapgnep la tomó hoy. Abiertostatus/need-triage
Dificultad 1/5 Menos de una hora Aptitud para principiantes 82/100
google-gemini/gemini-cli#30525 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
omdsh-dev/DSH-better-sidebar#1290 ·
Los mantenedores suelen responder en 1 día
-
Suggest a wallet: WalletChanPosiblemente ocupada @apoorvlathey la tomó hoy. Abiertoawaiting changes needs triage 📥
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
ethereum/ethereum-org-website#20000 · 3 comentarios ·
Los mantenedores suelen responder en 1 día