-
-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Delete file cache to complete public API
This removes the final dependency we had that didn't go through c-ray.h - The file cache. It was a hack I devised a while ago to facilitate network rendering, and it allowed me to avoid doing what this patch does, which is to write proper JSON serializing logic for most internal state. That's now done (for now, it lives in protocol/protocol.c), and simplifies many aspects of setting up and syncing with nodes. To make it possible to serialize everything, numerous other improvements popped up - Textures and shader graphs are now just arrays that live in the scene object, instead of the complicated refcounting I had there before. Meshes and instances just refer to those with indices now. This also resolves the bug I recently introduced where textures got loaded twice for no reason. Textures are also no longer borrowing the node graph memory pool. The API got some changes too, those material sets and vertex buffers now get controlled with handles instead of internally refcounted pointers, since they just live in a shared array. I'd imagine that some of the serialize/deserialize logic could be combined with json_loader, didn't really pay attention to that idea yet. Massive patch, but most of these changes really can't be separated out to multiple smaller steps - The old file cache did touch many things. I added a bunch of FIXMEs and TODOs again. The milestone of actually separating the project into a shared object + driver program is getting really close now! Really happy with this commit :^)
- Loading branch information
Showing
45 changed files
with
1,118 additions
and
548 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.