mirror of
https://github.com/aap/librw.git
synced 2025-12-19 08:59:51 +00:00
Fixed on windows.
This commit is contained in:
@@ -10,9 +10,11 @@ rwtest: $(OBJ) $(RWDIR)/librw-opengl.a /usr/local/lib/libglfw3.a
|
||||
$(CXX) $^ $(LDLIBS) -o $@
|
||||
|
||||
$(BUILDDIR)/%.o: %.cpp
|
||||
@mkdir -p $(@D)
|
||||
$(CXX) $(CFLAGS) -c $< -o $@
|
||||
|
||||
$(BUILDDIR)/%.d: %.cpp
|
||||
@mkdir -p $(@D)
|
||||
$(CXX) -MM -MT '$(patsubst %.cpp,$(BUILDDIR)%.o,$<)' $(CFLAGS) $< > $@
|
||||
|
||||
clean:
|
||||
|
||||
@@ -6,13 +6,15 @@ RWDIR=$(HOME)/src/librw
|
||||
LDLIBS=-static -lglfw3 -lglew32 -lopengl32 -lgdi32
|
||||
CFLAGS=-g -I$(RWDIR) -Wall -Wextra -DGLEW_STATIC
|
||||
|
||||
rwtest: $(OBJ) $(RWDIR)/librw.a
|
||||
rwtest: $(OBJ) $(RWDIR)/librw-opengl.a
|
||||
$(CXX) $^ $(LDLIBS) -o $@
|
||||
|
||||
$(BUILDDIR)/%.o: %.cpp
|
||||
@mkdir -p $(@D)
|
||||
$(CXX) $(CFLAGS) -c $< -o $@
|
||||
|
||||
$(BUILDDIR)/%.d: %.cpp
|
||||
@mkdir -p $(@D)
|
||||
$(CXX) -MM -MT '$(patsubst %.cpp,$(BUILDDIR)%.o,$<)' $(CFLAGS) $< > $@
|
||||
|
||||
dep: $(DEP)
|
||||
|
||||
@@ -183,7 +183,9 @@ init(void)
|
||||
Rw::CurrentTexDictionary = new Rw::TexDictionary;
|
||||
// Rw::Image::setSearchPath("/home/aap/gamedata/ps2/gtasa/models/gta3_archive/txd_extracted/");
|
||||
// Rw::Image::setSearchPath("/home/aap/gamedata/ps2/gtavc/MODELS/gta3_archive/txd_extracted/");
|
||||
Rw::Image::setSearchPath("/home/aap/gamedata/ps2/gtavc/MODELS/gta3_archive/txd_extracted/;/home/aap/gamedata/ps2/gtasa/models/gta3_archive/txd_extracted/");
|
||||
Rw::Image::setSearchPath(
|
||||
"/home/aap/gamedata/ps2/gtavc/MODELS/gta3_archive/txd_extracted/;/home/aap/gamedata/ps2/gtasa/models/gta3_archive/txd_extracted/");
|
||||
//"D:\\rockstargames\\ps2\\gtavc\\MODELS\\gta3_archive\\txd_extracted\\;D:\\rockstargames\\ps2\\gtasa\\models\\gta3_archive\\txd_extracted\\");
|
||||
Rw::Gl::RegisterNativeRaster();
|
||||
Rw::RegisterMaterialRightsPlugin();
|
||||
Rw::RegisterMatFXPlugin();
|
||||
@@ -199,7 +201,8 @@ init(void)
|
||||
Rw::RegisterMeshPlugin();
|
||||
|
||||
Rw::StreamFile in;
|
||||
in.open(filename, "rb");
|
||||
if(in.open(filename, "rb") == NULL)
|
||||
printf("couldn't open file\n");
|
||||
Rw::FindChunk(&in, Rw::ID_CLUMP, NULL, NULL);
|
||||
clump = Rw::Clump::streamRead(&in);
|
||||
assert(clump);
|
||||
|
||||
Reference in New Issue
Block a user