Timeline Prototype

This commit is contained in:
2026-06-13 11:48:56 +08:00
parent 43c70be574
commit c4bf9673a8
24 changed files with 501 additions and 58 deletions
+8
View File
@@ -3,6 +3,7 @@
#include <glad/gl.h>
#include <pxr/usd/usd/stage.h>
#include <pxr/usd/usd/timeCode.h>
#include <pxr/imaging/glf/drawTarget.h>
#include <pxr/usdImaging/usdImagingGL/engine.h>
#include <pxr/imaging/glf/simpleLight.h>
@@ -163,6 +164,11 @@ public:
if (val) m_cameraCacheDirty = true;
}
/// Current evaluation time (timeline frame). Drives Hydra rendering,
/// USD camera resolution, and bounding-box computation.
pxr::UsdTimeCode GetCurrentTimeCode() const { return m_currentTime; }
void SetCurrentTimeCode(pxr::UsdTimeCode t) { m_currentTime = t; }
// -----------------------------------------------------------------------
// Bounding box display
// -----------------------------------------------------------------------
@@ -267,6 +273,8 @@ private:
bool m_rendererInitialized;
bool m_forceRefresh;
pxr::UsdTimeCode m_currentTime = pxr::UsdTimeCode::Default();
int m_diagFrameCount;
// --- Grid GL resources (line geometry, reuses m_axisProgram / m_axisUniformMVP) ---