mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 08:21:24 +02:00
removed app from SendVoxelsOperationArgs since its available as singleton
This commit is contained in:
parent
8b867df762
commit
8e07bd42ea
1 changed files with 2 additions and 4 deletions
|
@ -1553,7 +1553,6 @@ void Application::chooseVoxelPaintColor() {
|
||||||
const int MAXIMUM_EDIT_VOXEL_MESSAGE_SIZE = 1500;
|
const int MAXIMUM_EDIT_VOXEL_MESSAGE_SIZE = 1500;
|
||||||
struct SendVoxelsOperationArgs {
|
struct SendVoxelsOperationArgs {
|
||||||
unsigned char* newBaseOctCode;
|
unsigned char* newBaseOctCode;
|
||||||
Application* app;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
bool Application::sendVoxelsOperation(VoxelNode* node, void* extraData) {
|
bool Application::sendVoxelsOperation(VoxelNode* node, void* extraData) {
|
||||||
|
@ -1585,7 +1584,8 @@ bool Application::sendVoxelsOperation(VoxelNode* node, void* extraData) {
|
||||||
codeColorBuffer[bytesInCode + GREEN_INDEX] = node->getColor()[GREEN_INDEX];
|
codeColorBuffer[bytesInCode + GREEN_INDEX] = node->getColor()[GREEN_INDEX];
|
||||||
codeColorBuffer[bytesInCode + BLUE_INDEX ] = node->getColor()[BLUE_INDEX ];
|
codeColorBuffer[bytesInCode + BLUE_INDEX ] = node->getColor()[BLUE_INDEX ];
|
||||||
|
|
||||||
args->app->_voxelEditSender.queueVoxelEditMessage(PACKET_TYPE_SET_VOXEL_DESTRUCTIVE, codeColorBuffer, codeAndColorLength);
|
getInstance()->_voxelEditSender.queueVoxelEditMessage(PACKET_TYPE_SET_VOXEL_DESTRUCTIVE,
|
||||||
|
codeColorBuffer, codeAndColorLength);
|
||||||
|
|
||||||
delete[] codeColorBuffer;
|
delete[] codeColorBuffer;
|
||||||
}
|
}
|
||||||
|
@ -1769,7 +1769,6 @@ void Application::importVoxels() {
|
||||||
// the server as an set voxel message, this will also rebase the voxels to the new location
|
// the server as an set voxel message, this will also rebase the voxels to the new location
|
||||||
unsigned char* calculatedOctCode = NULL;
|
unsigned char* calculatedOctCode = NULL;
|
||||||
SendVoxelsOperationArgs args;
|
SendVoxelsOperationArgs args;
|
||||||
args.app = this;
|
|
||||||
|
|
||||||
// we only need the selected voxel to get the newBaseOctCode, which we can actually calculate from the
|
// we only need the selected voxel to get the newBaseOctCode, which we can actually calculate from the
|
||||||
// voxel size/position details.
|
// voxel size/position details.
|
||||||
|
@ -1818,7 +1817,6 @@ void Application::pasteVoxels() {
|
||||||
// Recurse the clipboard tree, where everything is root relative, and send all the colored voxels to
|
// Recurse the clipboard tree, where everything is root relative, and send all the colored voxels to
|
||||||
// the server as an set voxel message, this will also rebase the voxels to the new location
|
// the server as an set voxel message, this will also rebase the voxels to the new location
|
||||||
SendVoxelsOperationArgs args;
|
SendVoxelsOperationArgs args;
|
||||||
args.app = this;
|
|
||||||
|
|
||||||
// we only need the selected voxel to get the newBaseOctCode, which we can actually calculate from the
|
// we only need the selected voxel to get the newBaseOctCode, which we can actually calculate from the
|
||||||
// voxel size/position details. If we don't have an actual selectedNode then use the mouseVoxel to create a
|
// voxel size/position details. If we don't have an actual selectedNode then use the mouseVoxel to create a
|
||||||
|
|
Loading…
Reference in a new issue