Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix broken lint since 04cc9de
  • Loading branch information
nerzhul committed Apr 18, 2017
1 parent 93c1d51 commit 5f2af7c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
22 changes: 11 additions & 11 deletions src/mesh_generator_thread.h
Expand Up @@ -53,10 +53,12 @@ struct QueuedMeshUpdate
*/
class MeshUpdateQueue
{
enum UpdateMode {
enum UpdateMode
{
FORCE_UPDATE,
SKIP_UPDATE_IF_ALREADY_CACHED,
};

public:
MeshUpdateQueue(Client *client);

Expand All @@ -68,7 +70,7 @@ class MeshUpdateQueue

// Returned pointer must be deleted
// Returns NULL if queue is empty
QueuedMeshUpdate * pop();
QueuedMeshUpdate *pop();

u32 size()
{
Expand All @@ -78,9 +80,9 @@ class MeshUpdateQueue

private:
Client *m_client;
std::vector<QueuedMeshUpdate*> m_queue;
std::vector<QueuedMeshUpdate *> m_queue;
std::set<v3s16> m_urgents;
std::map<v3s16, CachedMapBlockData*> m_cache;
std::map<v3s16, CachedMapBlockData *> m_cache;
Mutex m_mutex;

// TODO: Add callback to update these when g_settings changes
Expand All @@ -89,9 +91,9 @@ class MeshUpdateQueue
bool m_cache_smooth_lighting;
int m_meshgen_block_cache_size;

CachedMapBlockData* cacheBlock(Map *map, v3s16 p, UpdateMode mode,
size_t *cache_hit_counter=NULL);
CachedMapBlockData* getCachedBlock(const v3s16 &p);
CachedMapBlockData *cacheBlock(Map *map, v3s16 p, UpdateMode mode,
size_t *cache_hit_counter = NULL);
CachedMapBlockData *getCachedBlock(const v3s16 &p);
void fillDataFromMapBlockCache(QueuedMeshUpdate *q);
void cleanupCache();
};
Expand All @@ -102,10 +104,8 @@ struct MeshUpdateResult
MapBlockMesh *mesh;
bool ack_block_to_server;

MeshUpdateResult():
p(-1338,-1338,-1338),
mesh(NULL),
ack_block_to_server(false)
MeshUpdateResult()
: p(-1338, -1338, -1338), mesh(NULL), ack_block_to_server(false)
{
}
};
Expand Down
1 change: 1 addition & 0 deletions util/travis/clang-format-whitelist.txt
Expand Up @@ -169,6 +169,7 @@ src/map_settings_manager.cpp
src/map_settings_manager.h
src/mesh.cpp
src/mesh.h
src/mesh_generator_thread.cpp
src/metadata.cpp
src/metadata.h
src/mg_biome.cpp
Expand Down

0 comments on commit 5f2af7c

Please sign in to comment.