mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-21 11:39:51 -06:00
Update Ghoul version
Add initial Tracy profiling macros
This commit is contained in:
@@ -24,6 +24,8 @@
|
||||
|
||||
#include <openspace/util/syncbuffer.h>
|
||||
|
||||
#include <ghoul/misc/profiling.h>
|
||||
|
||||
namespace openspace {
|
||||
|
||||
SyncBuffer::SyncBuffer(size_t n)
|
||||
@@ -35,6 +37,8 @@ SyncBuffer::SyncBuffer(size_t n)
|
||||
SyncBuffer::~SyncBuffer() {} // NOLINT
|
||||
|
||||
void SyncBuffer::encode(const std::string& s) {
|
||||
ZoneScoped
|
||||
|
||||
int32_t anticpatedBufferSize = _encodeOffset + (sizeof(char) * s.size())
|
||||
+ sizeof(int32_t);
|
||||
if (anticpatedBufferSize >= _n) {
|
||||
@@ -53,6 +57,8 @@ void SyncBuffer::encode(const std::string& s) {
|
||||
}
|
||||
|
||||
std::string SyncBuffer::decode() {
|
||||
ZoneScoped
|
||||
|
||||
int32_t length;
|
||||
memcpy(
|
||||
reinterpret_cast<char*>(&length),
|
||||
|
||||
Reference in New Issue
Block a user