Skip to content

Commit

Permalink
fix: remove calls to removed DebugDrawer resize method
Browse files Browse the repository at this point in the history
  • Loading branch information
isaac-mason committed Aug 18, 2024
1 parent 175a8c8 commit d617943
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 14 deletions.
9 changes: 0 additions & 9 deletions examples/vite-worker-example/src/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,6 @@ const App = () => {
indices.buffer,
]);

const onResize = () => {
debugDrawer.resize(window.innerWidth, window.innerHeight);
};

onResize();

window.addEventListener('resize', onResize);

scene.add(debugDrawer);

return () => {
Expand All @@ -66,7 +58,6 @@ const App = () => {
}

scene.remove(debugDrawer);
window.removeEventListener('resize', onResize);
debugDrawer.dispose();
};
}, []);
Expand Down
4 changes: 0 additions & 4 deletions packages/recast-navigation-three/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,6 @@ import { DebugDrawer } from 'recast-navigation/three';

const debugDrawer = new DebugDrawer();

// resize the debug drawer when the window resizes
// required for rendering lines correctly
debugDrawer.resize(window.innerWidth, window.innerHeight);

// draw a navmesh
debugDrawer.drawNavMesh(navMesh);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ const DebugDraw = ({ example, showModel = false }: DebugDrawProps) => {
if (!success) return;

const debugDrawer = new DebugDrawer();
debugDrawer.resize(window.innerWidth, window.innerHeight);

if (example === DebugDrawExample.HEIGHTFIELD_SOLID) {
debugDrawer.drawHeightfieldSolid(intermediates.heightfield!);
Expand Down

0 comments on commit d617943

Please sign in to comment.