diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-10-21 02:09:59 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-10-24 02:25:19 +0300 |
commit | 070a668d04844610059aaedc80c49e9038fd1779 (patch) | |
tree | cad5c64972e45b4ee19cc8e11cdd9adedd7a2f08 /intern/cycles/device/device_network.h | |
parent | aa8b4c5d8124c0379eeee9eacd1a0887a573d7d7 (diff) |
Code refactor: move more memory allocation logic into device API.
* Remove tex_* and pixels_* functions, replace by mem_*.
* Add MEM_TEXTURE and MEM_PIXELS as memory types recognized by devices.
* No longer create device_memory and call mem_* directly, always go
through device_only_memory, device_vector and device_pixels.
Diffstat (limited to 'intern/cycles/device/device_network.h')
-rw-r--r-- | intern/cycles/device/device_network.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/intern/cycles/device/device_network.h b/intern/cycles/device/device_network.h index 8a53290f421..a38d962c0af 100644 --- a/intern/cycles/device/device_network.h +++ b/intern/cycles/device/device_network.h @@ -279,6 +279,11 @@ public: mem.name = name.c_str(); mem.data_pointer = 0; + + /* Can't transfer OpenGL texture over network. */ + if(mem.type == MEM_PIXELS) { + mem.type = MEM_WRITE_ONLY; + } } template<typename T> void read(T& data) |