summaryrefslogtreecommitdiff
path: root/src/KingSystem/System/VideoRecorder.cpp
blob: 53430f929f56b17167c7e266bf6d127c0c523abf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include "KingSystem/System/VideoRecorder.h"

namespace ksys {

SEAD_SINGLETON_DISPOSER_IMPL(VideoRecorder)

void VideoRecorder::postCalc() {
    if (!isCaptureEnabled())
        return;
    u32 framenum = mFrameNumber;
    sead::FixedSafeString<0x100> output;
    output.format("%s/%04d.tga", mFilename.cstr(), framenum);
    agl::utl::ScreenShotMgr::instance()->reserveCaptureWithDebugHeap(
        true, agl::TextureDataSerializerTGA::TGAFormat::_1, output, false);
    mFrameNumber++;
}

}  // namespace ksys