
surface's domain of u, v in [0, 1]. Cache the starting guess when projecting a point into a ratpoly surface, to avoid brute force searching for a good one every time. Split edges even if they aren't quite inside the trim curve, since the trim boundaries are pwl, not exact; unnecessary splits won't hurt, but failure to split when necessary will. Make the triangulation code use a better (but not perfect) epsilon, to avoid "can't find ear" failures on very fine meshes. And turn on compiler optimization! I had somehow forgotten about that, and it's a ~2x improvement. [git-p4: depot-paths = "//depot/solvespace/": change = 2026]
50 lines
1.4 KiB
Makefile
50 lines
1.4 KiB
Makefile
DEFINES = /D_WIN32_WINNT=0x500 /DISOLATION_AWARE_ENABLED /D_WIN32_IE=0x500 /DWIN32_LEAN_AND_MEAN /DWIN32 /DLIBRARY
|
|
# Use the multi-threaded static libc because libpng and zlib do; not sure if anything bad
|
|
# happens if those mix, but don't want to risk it.
|
|
CFLAGS = /W3 /nologo -MT -Iextlib -I..\..\common\win32 /D_DEBUG /D_CRT_SECURE_NO_WARNINGS /I. /I.. /Zi /EHs /O2
|
|
|
|
HEADERS = ..\solvespace.h ..\dsc.h ..\sketch.h ..\expr.h slvs.h
|
|
|
|
OBJDIR = obj
|
|
|
|
SSOBJS = $(OBJDIR)\util.obj \
|
|
$(OBJDIR)\entity.obj \
|
|
$(OBJDIR)\expr.obj \
|
|
$(OBJDIR)\constrainteq.obj \
|
|
$(OBJDIR)\system.obj \
|
|
|
|
|
|
W32OBJS = $(OBJDIR)\w32util.obj \
|
|
|
|
|
|
LIBOBJS = $(OBJDIR)\lib.obj \
|
|
|
|
|
|
LIBS = user32.lib gdi32.lib comctl32.lib advapi32.lib shell32.lib
|
|
|
|
all: $(OBJDIR)/ctest.exe
|
|
@cp $(OBJDIR)/ctest.exe .
|
|
ctest.exe
|
|
|
|
clean:
|
|
rm -f obj/*
|
|
|
|
$(OBJDIR)/slvs.lib: $(SSOBJS) $(LIBOBJS) $(W32OBJS)
|
|
@lib /OUT:$(OBJDIR)/slvs.lib $(SSOBJS) $(LIBOBJS) $(W32OBJS)
|
|
@echo slvs.lib
|
|
|
|
$(OBJDIR)/ctest.exe: example.c $(OBJDIR)/slvs.lib
|
|
@$(CC) $(CFLAGS) -Fe$(OBJDIR)/ctest.exe example.c $(OBJDIR)/slvs.lib $(LIBS)
|
|
@echo ctest.exe
|
|
|
|
$(SSOBJS): ..\$(@B).cpp $(HEADERS)
|
|
@$(CC) $(CFLAGS) $(DEFINES) -c -Fo$(OBJDIR)/$(@B).obj ..\$(@B).cpp
|
|
|
|
$(W32OBJS): ..\win32\$(@B).cpp $(HEADERS)
|
|
@$(CC) $(CFLAGS) $(DEFINES) -c -Fo$(OBJDIR)/$(@B).obj ..\win32\$(@B).cpp
|
|
|
|
$(LIBOBJS): $(@B).cpp $(HEADERS)
|
|
@$(CC) $(CFLAGS) $(DEFINES) -c -Fo$(OBJDIR)/$(@B).obj $(@B).cpp
|
|
|
|
|