#pragma once #include "shape.h" // Figura: Curva de Lissajous 3D // Comportamiento: Curva paramétrica 3D con rotación global y animación de fase // Ecuaciones: x(t) = A*sin(freq_x*t + phase_x), y(t) = A*sin(freq_y*t), z(t) = A*sin(freq_z*t + phase_z) class LissajousShape : public Shape { private: float freq_x_ = 0.0f; // Frecuencia en eje X float freq_y_ = 0.0f; // Frecuencia en eje Y float freq_z_ = 0.0f; // Frecuencia en eje Z float phase_x_ = 0.0f; // Desfase X (animado) float phase_z_ = 0.0f; // Desfase Z (animado) float rotation_x_ = 0.0f; // Rotación global en eje X (rad) float rotation_y_ = 0.0f; // Rotación global en eje Y (rad) float amplitude_ = 0.0f; // Amplitud de la curva (píxeles) int num_points_ = 0; // Cantidad total de puntos public: void generatePoints(int num_points, float screen_width, float screen_height) override; void update(float delta_time, float screen_width, float screen_height) override; void getPoint3D(int index, float& x, float& y, float& z) const override; const char* getName() const override { return "LISSAJOUS"; } float getScaleFactor(float screen_height) const override; };