An open API service indexing awesome lists of open source software.

https://github.com/danielearwicker/claude-3d-editor

Experiment using claude to develop a 3D object editor
https://github.com/danielearwicker/claude-3d-editor

Last synced: 8 months ago
JSON representation

Experiment using claude to develop a 3D object editor

Awesome Lists containing this project

README

          

Copy of aider input history, pruned to just my prompts:

# 2025-03-19 18:37:58.990458

+I want to generate a web app using react and parcel

# 2025-03-19 18:40:01.260861

+I want the main view of the app to be a 3d scene showing a cube that i can rotate by dragging with the mouse

# 2025-03-19 18:41:34.320915

+I don't want the cube to spin by itself

# 2025-03-19 18:43:01.099917

+I would like the ability to make edits to the scene interactively, so some way of grabbing the corners of the cube and moving them with the mouse

# 2025-03-19 19:38:18.956257

+The control points don't appear to be located at the vertices of the cube, and when I move them, the cube is deformed but not in a way that is predictable.

# 2025-03-19 19:41:36.098789

+When I drag to rotate the viewpoint the control points don't move with the cube.

# 2025-03-19 19:46:47.967042

+Would it be possible to support adding a new control point to the shape? It would create a new vertex and split the side of the existing shape. I'm imagining this would be a new mode in which you can click the surface that you want to add a vertex to. The existing surface would be replaced with multiple surfaces.

# 2025-03-19 19:50:06.469195

+The mouse interaction with the vertices seems to have stopped working. Only dragging to rotate still works. I wonder if it might be clearer if dragging to rotate only worked in View mode, and dragging to move the verticies only worked in Edit mode. Also Add mode doesn't work.

# 2025-03-19 19:53:09.304629

+Rotation is still happening in all modes. In Edit mode, it is still not possible to move a control point. In Add mode clicking on a surface does nothing.

# 2025-03-19 20:03:31.210746

+I see the problem. All the set up is in a useEffect hook, which has an empty dependencies list, so it only runs once. It calls setMode to change the mode state, but this is not visible to all the mouse handlers which were set up in useEffect and have closed over the initial value of mode (which is always edit). I tried added the mode to the useEffect dependency list, but this reset the entire state whenever I changed modes.

# 2025-03-19 20:10:35.147242

+Something is still not right. When I click the button for edit mode, it switches to edit mode and then instantly switches back to view mode.

# 2025-03-19 20:16:17.420802

+That last change has introduce several errors detected by my code editor. The variable cube is redeclared, same for controlPoints, inside the useEffect hook

# 2025-03-19 20:20:46.210711

+There was a bug in that change, the updateCubeGeometry was referenced in a dependency array before it was initialized, so I move it up. Now the site loads but the same issue exists as before: clicking to set the mode is immediately reversed as the mode changes back to View.

# 2025-03-19 20:24:40.908176

+Now I can switch modes, but control points don't appear in Edit mode.

# 2025-03-19 20:26:04.736006

+That seems better, but when I switch back to View mode to rotate the view, it resets the cube to its original shape.

# 2025-03-19 20:27:19.628477

+No, switching to view mode still resets the cube

# 2025-03-19 20:29:50.197765

+I have tested again and it is still resetting the state of the cube when I switch between modes. Also it resets the rotational view point. The state of the cube geometry and the point of view must not be affected by any change of mode

# 2025-03-19 20:36:34.593752

+I see the problem. The useEffect for scene setup has too many responsibilities. It sets up the cube geometry and also mousemove etc. listeners. Therefore it has handleMouseMove in its dependency array. handleMouseMove changes whenever the mode changes, and so the cube geometry is reset.

# 2025-03-19 21:08:03.896284

+That has fixed those issues. Now the adding mode: it makes the cube look wireframe. But when I switch to other modes, the wire edges disappear also and so nothing is displayed (except in Edit mode, the control points are displayed)

# 2025-03-19 21:12:25.000916

+In setViewMode there is a reference to controlPointsGroup which is not in scope in that function.

# 2025-03-19 21:14:51.170709

+So, the cube still becomes invisible after switching to add mode and back to view.

# 2025-03-19 21:18:10.833423

+So now the action of clicking to add a vertex seems to break it. After that the cube becomes invisible when switching back to view mode.

# 2025-03-19 21:44:37.524925

+Adding a vertex still causes a permanent change to the cube, removing all the shaded surfaces.