mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 19:59:28 +02:00
Fixed edge issue, increased default grid size to correspond to default
heightfield import.
This commit is contained in:
parent
3dbbbb72b0
commit
debc9b735d
2 changed files with 4 additions and 4 deletions
|
@ -2241,7 +2241,7 @@ void HeightfieldNodeRenderer::render(const HeightfieldNodePointer& node, const g
|
||||||
// quads for each edge that includes a transition, using indices of previously generated vertices
|
// quads for each edge that includes a transition, using indices of previously generated vertices
|
||||||
int reclampedX = qMin(clampedX, stackWidth - 1);
|
int reclampedX = qMin(clampedX, stackWidth - 1);
|
||||||
int reclampedZ = qMin(clampedZ, stackHeight - 1);
|
int reclampedZ = qMin(clampedZ, stackHeight - 1);
|
||||||
if (alpha0 != alpha1 && middleX) {
|
if (alpha0 != alpha1 && y > position && z > 0) {
|
||||||
const NormalIndex& index1 = lastIndexY;
|
const NormalIndex& index1 = lastIndexY;
|
||||||
const NormalIndex& index2 = lastIndicesZ[x].get(y - 1);
|
const NormalIndex& index2 = lastIndicesZ[x].get(y - 1);
|
||||||
const NormalIndex& index3 = lastIndicesZ[x].get(y);
|
const NormalIndex& index3 = lastIndicesZ[x].get(y);
|
||||||
|
@ -2269,7 +2269,7 @@ void HeightfieldNodeRenderer::render(const HeightfieldNodePointer& node, const g
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (alpha0 != alpha2) {
|
if (alpha0 != alpha2 && x > 0 && z > 0) {
|
||||||
const NormalIndex& index1 = lastIndicesZ[x].get(y);
|
const NormalIndex& index1 = lastIndicesZ[x].get(y);
|
||||||
const NormalIndex& index2 = lastIndicesZ[x - 1].get(y);
|
const NormalIndex& index2 = lastIndicesZ[x - 1].get(y);
|
||||||
const NormalIndex& index3 = lastIndicesX.get(y);
|
const NormalIndex& index3 = lastIndicesX.get(y);
|
||||||
|
@ -2301,7 +2301,7 @@ void HeightfieldNodeRenderer::render(const HeightfieldNodePointer& node, const g
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (alpha0 != alpha4 && middleZ) {
|
if (alpha0 != alpha4 && x > 0 && y > position) {
|
||||||
const NormalIndex& index1 = lastIndexY;
|
const NormalIndex& index1 = lastIndexY;
|
||||||
const NormalIndex& index2 = lastIndicesX.get(y - 1);
|
const NormalIndex& index2 = lastIndicesX.get(y - 1);
|
||||||
const NormalIndex& index3 = lastIndicesX.get(y);
|
const NormalIndex& index3 = lastIndicesX.get(y);
|
||||||
|
|
|
@ -97,7 +97,7 @@ MetavoxelEditor::MetavoxelEditor() :
|
||||||
_gridSpacing->setMinimum(-FLT_MAX);
|
_gridSpacing->setMinimum(-FLT_MAX);
|
||||||
_gridSpacing->setMaximum(FLT_MAX);
|
_gridSpacing->setMaximum(FLT_MAX);
|
||||||
_gridSpacing->setPrefix("2^");
|
_gridSpacing->setPrefix("2^");
|
||||||
_gridSpacing->setValue(-3.0);
|
_gridSpacing->setValue(0.0);
|
||||||
connect(_gridSpacing, SIGNAL(valueChanged(double)), SLOT(alignGridPosition()));
|
connect(_gridSpacing, SIGNAL(valueChanged(double)), SLOT(alignGridPosition()));
|
||||||
|
|
||||||
formLayout->addRow("Grid Position:", _gridPosition = new QDoubleSpinBox());
|
formLayout->addRow("Grid Position:", _gridPosition = new QDoubleSpinBox());
|
||||||
|
|
Loading…
Reference in a new issue