Fix triangle extruding face center position.
parent
fcfe51a28a
commit
d121632a98
|
@ -53,40 +53,40 @@ std::vector<QVector2D> CutFaceToPoints(CutFace cutFace) \
|
||||||
switch (cutFace) { \
|
switch (cutFace) { \
|
||||||
case CutFace::Quad: \
|
case CutFace::Quad: \
|
||||||
return { \
|
return { \
|
||||||
{-1.0, -1.0}, \
|
{(float)-1.0, (float)-1.0}, \
|
||||||
{ 1.0, -1.0}, \
|
{ (float)1.0, (float)-1.0}, \
|
||||||
{ 1.0, 1.0}, \
|
{ (float)1.0, (float)1.0}, \
|
||||||
{-1.0, 1.0}, \
|
{(float)-1.0, (float)1.0}, \
|
||||||
}; \
|
}; \
|
||||||
case CutFace::Triangle: \
|
case CutFace::Triangle: \
|
||||||
return { \
|
return { \
|
||||||
{-1.1547, -1.0}, \
|
{(float)-1.1527, (float)-0.6655}, \
|
||||||
{ 1.1547, -1.0}, \
|
{ (float)1.1527, (float)-0.6655}, \
|
||||||
{ 0.0, 1.0}, \
|
{ (float)0.0, (float)1.33447}, \
|
||||||
}; \
|
}; \
|
||||||
case CutFace::Pentagon: \
|
case CutFace::Pentagon: \
|
||||||
return { \
|
return { \
|
||||||
{ -0.6498, -0.8944}, \
|
{ (float)-0.6498, (float)-0.8944}, \
|
||||||
{ 0.6498, -0.8944}, \
|
{ (float)0.6498, (float)-0.8944}, \
|
||||||
{ 1.05146, 0.34164}, \
|
{ (float)1.05146, (float)0.34164}, \
|
||||||
{ 0.0, 1.10557}, \
|
{ (float)0.0, (float)1.10557}, \
|
||||||
{-1.05146, 0.34164}, \
|
{(float)-1.05146, (float)0.34164}, \
|
||||||
}; \
|
}; \
|
||||||
case CutFace::Hexagon: \
|
case CutFace::Hexagon: \
|
||||||
return { \
|
return { \
|
||||||
{ -0.577, -1.0}, \
|
{ (float)-0.577, (float)-1.0}, \
|
||||||
{ 0.577, -1.0}, \
|
{ (float)0.577, (float)-1.0}, \
|
||||||
{ 1.1547, 0.0}, \
|
{ (float)1.1547, (float)0.0}, \
|
||||||
{ 0.577, 1.0}, \
|
{ (float)0.577, (float)1.0}, \
|
||||||
{ -0.577, 1.0}, \
|
{ (float)-0.577, (float)1.0}, \
|
||||||
{-1.1547, 0.0}, \
|
{(float)-1.1547, (float)0.0}, \
|
||||||
}; \
|
}; \
|
||||||
default: \
|
default: \
|
||||||
return { \
|
return { \
|
||||||
{-1.0, -1.0}, \
|
{(float)-1.0, (float)-1.0}, \
|
||||||
{ 1.0, -1.0}, \
|
{ (float)1.0, (float)-1.0}, \
|
||||||
{ 1.0, 1.0}, \
|
{ (float)1.0, (float)1.0}, \
|
||||||
{-1.0, 1.0}, \
|
{(float)-1.0, (float)1.0}, \
|
||||||
}; \
|
}; \
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue