import React from 'react'; import { motion } from 'framer-motion'; import { Activity, Dumbbell, Gamepad2, Stethoscope, Play, CheckCircle2 } from 'lucide-react'; import ClickReveal from './ClickReveal'; import KeyTermBadge from './KeyTermBadge'; import { PoseSkeletonDemo } from './AnimatedDiagram'; export const chapter2Slides = [ // Slide 1: What is Pose Estimation? { content: (

What is Pose Estimation?

Chapter 2 â€Ē Slide 1 of 5

is like teaching a computer to understand body language!

It finds important points on your body — like your nose, shoulders, elbows, and knees — and connects them to create a "skeleton" that shows how you're moving.

Video games like Just Dance use pose estimation to track your dance moves in real-time!

) }, // Slide 2: Keypoints and Skeleton Lines { content: (

Keypoints & Skeleton

Building a digital body map

Keypoints

are the important spots on your body that the AI tracks — typically 17 points including your nose, eyes, shoulders, elbows, wrists, hips, knees, and ankles.

Skeleton Lines

Lines connect the keypoints to show your body structure — like a stick figure that moves exactly like you!

ðŸ’Ą Each keypoint has X, Y coordinates (position) and sometimes a confidence score!

) }, // Slide 3: Real-World Uses { content: (

Real-World Uses

Pose estimation helps everywhere!

{[ { icon: Dumbbell, title: "Sports & Fitness", description: "Coaches analyze athlete movements to improve technique. Fitness apps check if you're doing exercises correctly!", color: "from-purple-500 to-pink-500" }, { icon: Gamepad2, title: "Gaming & VR", description: "Motion-controlled games track your body to make you the controller. Dance games know exactly how you move!", color: "from-blue-500 to-purple-500" }, { icon: Stethoscope, title: "Healthcare", description: "Physical therapists use it to track patient recovery. It can even help detect early signs of movement disorders.", color: "from-emerald-500 to-teal-500" } ].map((item, i) => (

{item.title}

{item.description}

))}

Olympic coaches use pose estimation to analyze athletes frame-by-frame, finding improvements invisible to the human eye!

) }, // Slide 4: Animated Stick Figure { content: (

See It Move!

Watch pose estimation in action

{[ { label: "Real-time Tracking", icon: "⚡" }, { label: "17 Keypoints", icon: "📍" }, { label: "Smooth Motion", icon: "🌊" } ].map((item, i) => ( {item.icon}

{item.label}

))}
) }, // Slide 5: Chapter Summary { content: (
🎊

Chapter Complete!

You've mastered Pose Estimation

Key Takeaways

{[ { icon: "ðŸŽŊ", text: "Pose estimation tracks body movements using keypoints" }, { icon: "ðŸĶī", text: "17 keypoints create a full body skeleton" }, { icon: "âš―", text: "Used in sports, gaming, healthcare, and more" }, { icon: "⚡", text: "Works in real-time for interactive applications" } ].map((item, i) => (
{item.icon}

{item.text}

))}
ðŸŽŊ
5
Slides Completed
📍
17
Body Keypoints
ðŸ‘Ĩ
Multi
Person Tracking
) } ]; function AnimatedStickFigure() { const [pose, setPose] = React.useState(0); const poses = ['standing', 'waving']; React.useEffect(() => { const interval = setInterval(() => { setPose(p => (p + 1) % poses.length); }, 2000); return () => clearInterval(interval); }, []); const poseConfigs = { standing: { head: { x: 50, y: 15 }, neck: { x: 50, y: 22 }, lshoulder: { x: 38, y: 25 }, rshoulder: { x: 62, y: 25 }, lelbow: { x: 32, y: 38 }, relbow: { x: 68, y: 38 }, lwrist: { x: 30, y: 50 }, rwrist: { x: 70, y: 50 }, hip: { x: 50, y: 50 }, lhip: { x: 42, y: 52 }, rhip: { x: 58, y: 52 }, lknee: { x: 42, y: 70 }, rknee: { x: 58, y: 70 }, lankle: { x: 42, y: 88 }, rankle: { x: 58, y: 88 } }, waving: { head: { x: 50, y: 15 }, neck: { x: 50, y: 22 }, lshoulder: { x: 38, y: 25 }, rshoulder: { x: 62, y: 25 }, lelbow: { x: 32, y: 38 }, relbow: { x: 75, y: 15 }, lwrist: { x: 30, y: 50 }, rwrist: { x: 85, y: 8 }, hip: { x: 50, y: 50 }, lhip: { x: 42, y: 52 }, rhip: { x: 58, y: 52 }, lknee: { x: 42, y: 70 }, rknee: { x: 58, y: 70 }, lankle: { x: 42, y: 88 }, rankle: { x: 58, y: 88 } } }; const currentPose = poseConfigs[poses[pose]]; const bones = [ ['head', 'neck'], ['neck', 'lshoulder'], ['neck', 'rshoulder'], ['lshoulder', 'lelbow'], ['rshoulder', 'relbow'], ['lelbow', 'lwrist'], ['relbow', 'rwrist'], ['neck', 'hip'], ['hip', 'lhip'], ['hip', 'rhip'], ['lhip', 'lknee'], ['rhip', 'rknee'], ['lknee', 'lankle'], ['rknee', 'rankle'], ]; return (
{/* Bones */} {bones.map(([from, to], i) => ( ))} {/* Keypoints */} {Object.entries(currentPose).map(([key, pos], i) => ( ))}
{/* Pose Label */} {poses[pose].charAt(0).toUpperCase() + poses[pose].slice(1)}
); }