mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Cycles: Cleanup, trailing whitespace
This commit is contained in:
parent
76c97aaff9
commit
46da985c8e
2 changed files with 11 additions and 13 deletions
|
|
@ -14,7 +14,6 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/scene.h"
|
||||
|
|
@ -293,7 +292,7 @@ static void create_mesh_volume_attribute(BL::Object& b_ob,
|
|||
|
||||
if(!b_domain)
|
||||
return;
|
||||
|
||||
|
||||
Attribute *attr = mesh->attributes.add(std);
|
||||
VoxelAttribute *volume_data = attr->data_voxel();
|
||||
bool is_float, is_linear;
|
||||
|
|
@ -982,7 +981,7 @@ Mesh *BlenderSync::sync_mesh(BL::Object& b_ob,
|
|||
else
|
||||
used_shaders.push_back(scene->default_surface);
|
||||
}
|
||||
|
||||
|
||||
/* test if we need to sync */
|
||||
int requested_geometry_flags = Mesh::GEOMETRY_NONE;
|
||||
if(render_layer.use_surfaces) {
|
||||
|
|
@ -1017,12 +1016,12 @@ Mesh *BlenderSync::sync_mesh(BL::Object& b_ob,
|
|||
/* ensure we only sync instanced meshes once */
|
||||
if(mesh_synced.find(mesh) != mesh_synced.end())
|
||||
return mesh;
|
||||
|
||||
|
||||
mesh_synced.insert(mesh);
|
||||
|
||||
/* create derived mesh */
|
||||
array<int> oldtriangle = mesh->triangles;
|
||||
|
||||
|
||||
/* compares curve_keys rather than strands in order to handle quick hair
|
||||
* adjustments in dynamic BVH - other methods could probably do this better*/
|
||||
array<float3> oldcurve_keys = mesh->curve_keys;
|
||||
|
|
@ -1111,7 +1110,7 @@ Mesh *BlenderSync::sync_mesh(BL::Object& b_ob,
|
|||
if(memcmp(&oldcurve_radius[0], &mesh->curve_radius[0], sizeof(float)*oldcurve_radius.size()) != 0)
|
||||
rebuild = true;
|
||||
}
|
||||
|
||||
|
||||
mesh->tag_update(scene, rebuild);
|
||||
|
||||
return mesh;
|
||||
|
|
@ -1140,7 +1139,7 @@ void BlenderSync::sync_mesh_motion(BL::Object& b_ob,
|
|||
if(scene->need_motion() == Scene::MOTION_BLUR) {
|
||||
if(!mesh->use_motion_blur)
|
||||
return;
|
||||
|
||||
|
||||
/* see if this mesh needs motion data at this time */
|
||||
vector<float> object_times = object->motion_times();
|
||||
bool found = false;
|
||||
|
|
@ -1172,7 +1171,7 @@ void BlenderSync::sync_mesh_motion(BL::Object& b_ob,
|
|||
|
||||
if(!numverts && !numkeys)
|
||||
return;
|
||||
|
||||
|
||||
/* skip objects without deforming modifiers. this is not totally reliable,
|
||||
* would need a more extensive check to see which objects are animated */
|
||||
BL::Mesh b_mesh(PointerRNA_NULL);
|
||||
|
|
|
|||
|
|
@ -299,7 +299,7 @@ static inline uint get_layer(const BL::Array<int, 20>& array)
|
|||
for(uint i = 0; i < 20; i++)
|
||||
if(array[i])
|
||||
layer |= (1 << i);
|
||||
|
||||
|
||||
return layer;
|
||||
}
|
||||
|
||||
|
|
@ -434,7 +434,7 @@ static inline string get_string(PointerRNA& ptr, const char *name)
|
|||
string str(cstr);
|
||||
if(cstr != cstrbuf)
|
||||
MEM_freeN(cstr);
|
||||
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
|
|
@ -451,7 +451,7 @@ static inline string blender_absolute_path(BL::BlendData& b_data,
|
|||
{
|
||||
if(path.size() >= 2 && path[0] == '/' && path[1] == '/') {
|
||||
string dirname;
|
||||
|
||||
|
||||
if(b_id.library()) {
|
||||
BL::ID b_library_id(b_id.library());
|
||||
dirname = blender_absolute_path(b_data,
|
||||
|
|
@ -544,7 +544,7 @@ static inline BL::SmokeDomainSettings object_smoke_domain_find(BL::Object& b_ob)
|
|||
return b_smd.domain_settings();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return BL::SmokeDomainSettings(PointerRNA_NULL);
|
||||
}
|
||||
|
||||
|
|
@ -816,4 +816,3 @@ protected:
|
|||
CCL_NAMESPACE_END
|
||||
|
||||
#endif /* __BLENDER_UTIL_H__ */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue