jtmzheng / 3dss

2 stars 0 forks source link

Serialize model data. #8

Closed araghava closed 9 years ago

araghava commented 10 years ago

We should be able to serialize models when we load them. For example, when we load an object file (say foo.obj), we should be able to save it as src/cache/foo.model. Then our ModelFactory can look for foo.model and create the model from the serialized data if foo.model exists, rather than parsing foo.obj every time.

This is a performance win if we can serialize all the models needed for the game as parsing obj/mtl files is much more expensive than just loading the serialized model object.

jtmzheng commented 10 years ago

Sure.