MCPcopy Create free account
hub / github.com/FastLED/FastLED / seek

Method seek

tests/fl/fx/video.cpp:66–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

64 size_t tell() override { return mPos; }
65 const char *path() const override { return "fake"; }
66 bool seek(size_t pos, fl::seek_dir dir) override {
67 if (dir == fl::seek_dir::beg) { this->mPos = pos; }
68 else if (dir == fl::seek_dir::cur) { this->mPos += pos; }
69 else { this->mPos = data.size() + pos; }
70 return true;
71 }
72 using fl::filebuf::seek; // single-arg overload
73 void close() override {}
74 bool is_eof() const override { return mPos >= data.size(); }

Callers 4

vorbis.hppFile · 0.45
mpeg1.hppFile · 0.45
FL_TEST_FILEFunction · 0.45
FL_TEST_FILEFunction · 0.45

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected