| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent bae84b2 commit f6a774d
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -917,13 +917,13 @@ void SolveSpaceUI::ExportMeshAsQ3doTo(FILE *f, SMesh *sm) { | |||
| 917 | 917 | } | |
| 918 | 918 | ||
| 919 | 919 | Vector faceNormal = t.Normal(); | |
| 920 | - auto a = q3d::Vector3(t.a.x/s, t.a.y/s, t.a.z/s); | ||
| 921 | - auto b = q3d::Vector3(t.b.x/s, t.b.y/s, t.b.z/s); | ||
| 922 | - auto c = q3d::Vector3(t.c.x/s, t.c.y/s, t.c.z/s); | ||
| 923 | - auto fn = q3d::Vector3(faceNormal.x, faceNormal.y, faceNormal.x); | ||
| 924 | - auto n1 = q3d::Vector3(t.normals[0].x, t.normals[0].y, t.normals[0].z); | ||
| 925 | - auto n2 = q3d::Vector3(t.normals[1].x, t.normals[1].y, t.normals[1].z); | ||
| 926 | - auto n3 = q3d::Vector3(t.normals[2].x, t.normals[2].y, t.normals[2].z); | ||
| 920 | + auto a = q3d::Vector3((float)(t.a.x/s), (float)(t.a.y/s), (float)(t.a.z/s)); | ||
| 921 | + auto b = q3d::Vector3((float)(t.b.x/s), (float)(t.b.y/s), (float)(t.b.z/s)); | ||
| 922 | + auto c = q3d::Vector3((float)(t.c.x/s), (float)(t.c.y/s), (float)(t.c.z/s)); | ||
| 923 | + auto fn = q3d::Vector3((float)faceNormal.x, (float)faceNormal.y, (float)faceNormal.x); | ||
| 924 | + auto n1 = q3d::Vector3((float)t.normals[0].x, (float)t.normals[0].y, (float)t.normals[0].z); | ||
| 925 | + auto n2 = q3d::Vector3((float)t.normals[1].x, (float)t.normals[1].y, (float)t.normals[1].z); | ||
| 926 | + auto n3 = q3d::Vector3((float)t.normals[2].x, (float)t.normals[2].y, (float)t.normals[2].z); | ||
| 927 | 927 | auto tri = q3d::CreateTriangle(builder, &a, &b, &c, &fn, &n1, &n2, &n3); | |
| 928 | 928 | materialTriangles[color].push_back(tri); | |
| 929 | 929 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1227,7 +1227,7 @@ class WindowImplWin32 final : public Window { | |||
| 1227 | 1227 | } | |
| 1228 | 1228 | ||
| 1229 | 1229 | void SetCursor(Cursor cursor) override { | |
| 1230 | - LPWSTR cursorName; | ||
| 1230 | + LPWSTR cursorName = IDC_ARROW; | ||
| 1231 | 1231 | switch(cursor) { | |
| 1232 | 1232 | case Cursor::POINTER: cursorName = IDC_ARROW; break; | |
| 1233 | 1233 | case Cursor::HAND: cursorName = IDC_HAND; break; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -285,8 +285,8 @@ class SurfaceRenderer : public ViewportCanvas { | |||
| 285 | 285 | const Camera &GetCamera() const override { return camera; } | |
| 286 | 286 | ||
| 287 | 287 | // ViewportCanvas interface. | |
| 288 | - void SetCamera(const Camera &camera) override { this->camera = camera; } | ||
| 289 | - void SetLighting(const Lighting &lighting) override { this->lighting = lighting; } | ||
| 288 | + void SetCamera(const Camera &cam) override { this->camera = cam; } | ||
| 289 | + void SetLighting(const Lighting &light) override { this->lighting = light; } | ||
| 290 | 290 | ||
| 291 | 291 | void DrawLine(const Vector &a, const Vector &b, hStroke hcs) override; | |
| 292 | 292 | void DrawEdges(const SEdgeList &el, hStroke hcs) override; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -802,7 +802,6 @@ void SolveSpaceUI::MenuAnalyze(Command id) { | |||
| 802 | 802 | case Command::AREA: { | |
| 803 | 803 | Group *g = SK.GetGroup(SS.GW.activeGroup); | |
| 804 | 804 | SS.GW.GroupSelection(); | |
| 805 | - auto const &gs = SS.GW.gs; | ||
| 806 | 805 | ||
| 807 | 806 | if(gs.faces > 0) { | |
| 808 | 807 | std::vector<uint32_t> faces; | |
@@ -844,8 +843,8 @@ void SolveSpaceUI::MenuAnalyze(Command id) { | |||
| 844 | 843 | if(gs.n > 0 && gs.n == gs.entities) { | |
| 845 | 844 | double perimeter = 0.0; | |
| 846 | 845 | for(int i = 0; i < gs.entities; i++) { | |
| 847 | - Entity *e = SK.entity.FindById(gs.entity[i]); | ||
| 848 | - SEdgeList *el = e->GetOrGenerateEdges(); | ||
| 846 | + Entity *en = SK.entity.FindById(gs.entity[i]); | ||
| 847 | + SEdgeList *el = en->GetOrGenerateEdges(); | ||
| 849 | 848 | for(const SEdge &e : el->l) { | |
| 850 | 849 | perimeter += e.b.Minus(e.a).Magnitude(); | |
| 851 | 850 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -604,7 +604,7 @@ void TextWindow::ScreenStepDimGo(int link, uint32_t v) { | |||
| 604 | 604 | if(time - SS.TW.stepDim.time < STEP_MILLIS) { | |
| 605 | 605 | SS.TW.stepDim.timer->RunAfterNextFrame(); | |
| 606 | 606 | } else { | |
| 607 | - SS.TW.stepDim.timer->RunAfter(time - SS.TW.stepDim.time - STEP_MILLIS); | ||
| 607 | + SS.TW.stepDim.timer->RunAfter((unsigned)(time - SS.TW.stepDim.time - STEP_MILLIS)); | ||
| 608 | 608 | } | |
| 609 | 609 | SS.TW.stepDim.time = time; | |
| 610 | 610 | } else { | |
@@ -758,7 +758,8 @@ void TextWindow::EditControlDone(std::string s) { | |||
| 758 | 758 | ||
| 759 | 759 | Group *g = SK.group.FindByIdNoOops(SS.TW.shown.group); | |
| 760 | 760 | if(!g) break; | |
| 761 | - g->color = RgbaColor::FromFloat(rgb.x, rgb.y, rgb.z, g->color.alphaF()); | ||
| 761 | + g->color = RgbaColor::FromFloat((float)rgb.x, (float)rgb.y, (float)rgb.z, | ||
| 762 | + g->color.alphaF()); | ||
| 762 | 763 | ||
| 763 | 764 | SS.MarkGroupDirty(g->h); | |
| 764 | 765 | SS.GW.ClearSuper(); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments