Blender V2.61 - r43446
|
#include <assert.h>
#include "MEM_guardedalloc.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "DNA_material_types.h"
#include "rayintersection.h"
#include "rayobject.h"
#include "raycounter.h"
#include "render_types.h"
Go to the source code of this file.
Definition in file rayobject.cpp.
Definition at line 288 of file rayobject.cpp.
References Isect::check, Isect::dir, Isect::dist, Isect::face, RayFace::face, Isect::hit, isec_tri_quad(), isec_tri_quad_neighbour(), Isect::isect, Isect::last_hit, RayFace::ob, Isect::ob, Isect::orig, rayface_from_vlak(), RE_CHECK_VLR_BAKE, RE_CHECK_VLR_NON_SOLID_MATERIAL, RE_CHECK_VLR_RENDER, RE_RC_COUNT, RE_SKIP_VLR_NEIGHBOUR, Isect::skip, Isect::start, Isect::u, Isect::v, VlakRen::v1, VlakRen::v2, VlakRen::v3, VlakRen::v4, vlr_check_bake(), vlr_check_intersect(), and vlr_check_intersect_solid().
Referenced by RE_rayobject_intersect().
MALWAYS_INLINE int isec_tri_quad | ( | float | start[3], |
float | dir[3], | ||
RayFace * | face, | ||
float | uv[2], | ||
float * | lambda | ||
) |
Definition at line 138 of file rayobject.cpp.
References copy_v3_v3(), cross_v3_v3v3(), dot_v3v3(), RE_rayface_isQuad, RE_RAYTRACE_EPSILON, sub_v3_v3v3(), RayFace::v1, RayFace::v2, RayFace::v3, and RayFace::v4.
Referenced by intersect_rayface().
MALWAYS_INLINE int isec_tri_quad_neighbour | ( | float | start[3], |
float | dir[3], | ||
RayFace * | face | ||
) |
Definition at line 221 of file rayobject.cpp.
References copy_v3_v3(), cross_v3_v3v3(), dot_v3v3(), negate_v3_v3(), RE_rayface_isQuad, RE_RAYTRACE_EPSILON, sub_v3_v3v3(), RayFace::v1, RayFace::v2, RayFace::v3, and RayFace::v4.
Referenced by intersect_rayface().
MALWAYS_INLINE RayObject* rayface_from_coords | ( | RayFace * | rayface, |
void * | ob, | ||
void * | face, | ||
float * | v1, | ||
float * | v2, | ||
float * | v3, | ||
float * | v4 | ||
) |
Definition at line 53 of file rayobject.cpp.
References copy_v3_v3(), RayFace::face, RayFace::ob, RayFace::quad, RE_rayobject_unalignRayFace, RayFace::v1, RayFace::v2, RayFace::v3, and RayFace::v4.
Referenced by rayface_from_vlak(), and RE_rayface_from_vlak().
MALWAYS_INLINE void rayface_from_vlak | ( | RayFace * | rayface, |
ObjectInstanceRen * | obi, | ||
VlakRen * | vlr | ||
) |
Definition at line 76 of file rayobject.cpp.
References VertRen::co, ObjectInstanceRen::mat, mul_m4_v3(), rayface_from_coords(), RE_rayface_isQuad, ObjectInstanceRen::transform_primitives, RayFace::v1, VlakRen::v1, RayFace::v2, VlakRen::v2, RayFace::v3, VlakRen::v3, RayFace::v4, and VlakRen::v4.
Referenced by intersect_rayface(), RE_rayobject_intersect(), and RE_rayobject_merge_bb().
RayObject* RE_rayface_from_vlak | ( | RayFace * | rayface, |
ObjectInstanceRen * | obi, | ||
VlakRen * | vlr | ||
) |
Definition at line 91 of file rayobject.cpp.
References VertRen::co, rayface_from_coords(), VlakRen::v1, VlakRen::v2, VlakRen::v3, and VlakRen::v4.
Referenced by makeraytree_object(), and makeraytree_single().
Definition at line 449 of file rayobject.cpp.
References RayObjectAPI::add, RayObject::api, and RE_rayobject_align.
Referenced by makeraytree_object(), and makeraytree_single().
float RE_rayobject_cost | ( | RayObject * | r | ) |
Definition at line 467 of file rayobject.cpp.
References RayObject::api, assert, RayObjectAPI::cost, RE_rayobject_align, RE_rayobject_isRayAPI, RE_rayobject_isRayFace, and RE_rayobject_isVlakPrimitive.
Referenced by RE_rayobject_instance_cost(), and rtbuild_add().
void RE_rayobject_done | ( | RayObject * | r | ) |
Definition at line 455 of file rayobject.cpp.
References RayObject::api, RayObjectAPI::done, and RE_rayobject_align.
Referenced by makeraytree_object(), and makeraytree_single().
void RE_rayobject_free | ( | RayObject * | r | ) |
Definition at line 461 of file rayobject.cpp.
References RayObject::api, RayObjectAPI::free, and RE_rayobject_align.
Referenced by free_renderdata_tables(), freeraytree(), and makeraytree_object().
Definition at line 519 of file rayobject.cpp.
References RayObject::api, assert, RayObjectAPI::hint_bb, RE_rayobject_align, RE_rayobject_isRayAPI, RE_rayobject_isRayFace, and RE_rayobject_isVlakPrimitive.
Referenced by ray_ao_qmc(), ray_ao_spheresamp(), ray_shadow_jitter(), and ray_shadow_qmc().
Definition at line 421 of file rayobject.cpp.
References RayObject::api, assert, VlakPrimitive::face, intersect_rayface(), VlakPrimitive::ob, RayObjectAPI::raycast, rayface_from_vlak(), RE_rayobject_align, RE_rayobject_isRayAPI, RE_rayobject_isRayFace, and RE_rayobject_isVlakPrimitive.
Referenced by bvh_callback(), bvh_node_stack_raycast(), intersect(), RE_rayobject_instance_intersect(), RE_rayobject_raycast(), and testnode().
void RE_rayobject_merge_bb | ( | RayObject * | r, |
float * | min, | ||
float * | max | ||
) |
Definition at line 486 of file rayobject.cpp.
References RayObject::api, assert, RayObjectAPI::bb, DO_MINMAX, VlakPrimitive::face, VlakPrimitive::ob, rayface_from_vlak(), RE_rayface_isQuad, RE_rayobject_align, RE_rayobject_isRayAPI, RE_rayobject_isRayFace, RE_rayobject_isVlakPrimitive, RayFace::v1, RayFace::v2, RayFace::v3, and RayFace::v4.
Referenced by bvh_node_merge_bb(), makeraytree(), RE_rayobject_blibvh_add(), RE_rayobject_instance_bb(), RE_rayobject_octree_done(), rtbuild_add(), and rtbuild_calc_bb().
Definition at line 371 of file rayobject.cpp.
References Isect::bv_index, Isect::dir, Isect::hint, Isect::hit, i, Isect::idot_axis, Isect::last_hit, Isect::mode, RE_RAY_SHADOW, RE_rayobject_intersect(), and RE_RC_COUNT.
Referenced by bake_intersect_tree(), intersect_outside_volume(), ray_ao_qmc(), ray_ao_spheresamp(), ray_shadow(), ray_shadow_jitter(), ray_shadow_qmc(), ray_trace_shadow_rad(), ray_trace_shadow_tra(), traceray(), vol_get_bounds(), vol_get_shadow(), and vol_trace_behind().
void RE_rayobject_set_control | ( | RayObject * | r, |
void * | data, | ||
RE_rayobjectcontrol_test_break_callback | test_break | ||
) |
Definition at line 544 of file rayobject.cpp.
References RayObject::control, data, RayObjectControl::data, RE_rayobject_align, RE_rayobject_isRayAPI, test_break(), and RayObjectControl::test_break.
int RE_rayobjectcontrol_test_break | ( | RayObjectControl * | control | ) |
Definition at line 536 of file rayobject.cpp.
References RayObjectControl::data, and RayObjectControl::test_break.
Referenced by bvh_done< VBVHTree >(), rtbuild_done(), and BuildBinaryVBVH< Node >::test_break().
RayObject* RE_vlakprimitive_from_vlak | ( | VlakPrimitive * | face, |
struct ObjectInstanceRen * | obi, | ||
struct VlakRen * | vlr | ||
) |
Definition at line 98 of file rayobject.cpp.
References VlakPrimitive::face, VlakPrimitive::ob, and RE_rayobject_unalignVlakPrimitive.
Referenced by makeraytree_object(), and makeraytree_single().
MALWAYS_INLINE int vlr_check_bake | ( | Isect * | is, |
ObjectInstanceRen * | obi, | ||
VlakRen * | UNUSEDvlr | ||
) |
Definition at line 131 of file rayobject.cpp.
References ObjectRen::ob, ObjectInstanceRen::obr, and Isect::userdata.
Referenced by intersect_rayface().
MALWAYS_INLINE int vlr_check_intersect | ( | Isect * | is, |
ObjectInstanceRen * | obi, | ||
VlakRen * | vlr | ||
) |
Definition at line 108 of file rayobject.cpp.
References VlakRen::flag, Isect::lay, ObjectInstanceRen::lay, MA_ONLYCAST, VlakRen::mat, Isect::mode, Material::mode, R_TRACEBLE, and RE_RAY_MIRROR.
Referenced by intersect_rayface().
MALWAYS_INLINE int vlr_check_intersect_solid | ( | Isect * | UNUSEDis, |
ObjectInstanceRen * | UNUSEDobi, | ||
VlakRen * | vlr | ||
) |
Definition at line 122 of file rayobject.cpp.
References MA_TYPE_SURFACE, VlakRen::mat, and Material::material_type.
Referenced by intersect_rayface().