2017-01-01 17:15:57 -08:00
|
|
|
#ifndef VOXEL_PROVIDER_H
|
|
|
|
#define VOXEL_PROVIDER_H
|
|
|
|
|
2018-09-19 12:25:04 -07:00
|
|
|
#include <core/resource.h>
|
2017-01-01 17:15:57 -08:00
|
|
|
#include "voxel_buffer.h"
|
|
|
|
|
2017-08-14 17:24:52 -07:00
|
|
|
class VoxelProvider : public Resource {
|
|
|
|
GDCLASS(VoxelProvider, Resource)
|
2017-01-01 17:15:57 -08:00
|
|
|
public:
|
2017-08-28 06:42:54 -07:00
|
|
|
virtual void emerge_block(Ref<VoxelBuffer> out_buffer, Vector3i origin_in_voxels);
|
|
|
|
virtual void immerge_block(Ref<VoxelBuffer> buffer, Vector3i origin_in_voxels);
|
2017-01-01 17:15:57 -08:00
|
|
|
|
|
|
|
protected:
|
|
|
|
static void _bind_methods();
|
|
|
|
|
2017-08-28 06:42:54 -07:00
|
|
|
void _emerge_block(Ref<VoxelBuffer> out_buffer, Vector3 origin_in_voxels);
|
|
|
|
void _immerge_block(Ref<VoxelBuffer> buffer, Vector3 origin_in_voxels);
|
2017-01-01 17:15:57 -08:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // VOXEL_PROVIDER_H
|