显示线条起始点
parent
bfbcd4aac8
commit
3d80d98513
|
@ -31,7 +31,7 @@
|
||||||
<Import Project="$(QtMsBuild)\qt_defaults.props" />
|
<Import Project="$(QtMsBuild)\qt_defaults.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'" Label="QtSettings">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'" Label="QtSettings">
|
||||||
<QtInstall>5.15.0_msvc2019_64</QtInstall>
|
<QtInstall>5.15.2_msvc2019_64</QtInstall>
|
||||||
<QtModules>core;gui;widgets</QtModules>
|
<QtModules>core;gui;widgets</QtModules>
|
||||||
<QtBuildConfig>debug</QtBuildConfig>
|
<QtBuildConfig>debug</QtBuildConfig>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
|
|
||||||
//QVector3D lightPositions[] = { 2000 * QVector3D(0.2, 4, 1).normalized(), QVector3D(100,100,100) ,QVector3D(-100,100,100) ,QVector3D(100,100,-100) };
|
//QVector3D lightPositions[] = { 2000 * QVector3D(0.2, 4, 1).normalized(), QVector3D(100,100,100) ,QVector3D(-100,100,100) ,QVector3D(100,100,-100) };
|
||||||
QVector3D lightColors[] = { 20 * QVector3D(0.7529,0.7450,0.6784).normalized(), QVector3D(0,0,0) ,QVector3D(0,0,0) ,QVector3D(0,0,0) };
|
QVector3D lightColors[] = { 20 * QVector3D(0.7529,0.7450,0.6784).normalized(), QVector3D(0,0,0) ,QVector3D(0,0,0) ,QVector3D(0,0,0) };
|
||||||
static float sunPitch = 90, sunYaw = 80;
|
static float sunPitch = 105, sunYaw = 80;
|
||||||
static int sunSpeed = 10;
|
static int sunSpeed = 10;
|
||||||
|
|
||||||
RendererWidget::RendererWidget(QWidget* parent)
|
RendererWidget::RendererWidget(QWidget* parent)
|
||||||
|
|
|
@ -765,7 +765,10 @@ bool drawElement(uint elementIndex, vec2 localUV, out vec3 color, inout vec3 deb
|
||||||
elementData[pointsOffset + 2 * p2Index + 1]);
|
elementData[pointsOffset + 2 * p2Index + 1]);
|
||||||
vec2 p3 = vec2(elementData[pointsOffset + 2 * p3Index],
|
vec2 p3 = vec2(elementData[pointsOffset + 2 * p3Index],
|
||||||
elementData[pointsOffset + 2 * p3Index + 1]);
|
elementData[pointsOffset + 2 * p3Index + 1]);
|
||||||
|
if(distance(localUV, p0)<0.01)
|
||||||
|
if( bound.z==p0.x )
|
||||||
|
debugBVH = vec3(0,0,1);
|
||||||
|
else debugBVH = vec3(1,1,1);
|
||||||
if (p0 == p1 && p2 == p3)
|
if (p0 == p1 && p2 == p3)
|
||||||
{
|
{
|
||||||
num_its += segment_int_test(localUV, p0, p3);
|
num_its += segment_int_test(localUV, p0, p3);
|
||||||
|
|
Loading…
Reference in New Issue