Cleanup: docy comments beginning with '/**' don't end with '**/'
This commit is contained in:
parent
9b10b3930b
commit
54f89e8704
|
@ -123,7 +123,7 @@ bool EEVEE_shadows_cube_setup(EEVEE_LightsInfo *linfo, const EEVEE_Light *evli,
|
|||
* Note that this may be a rough approximation an may not converge to a perfectly
|
||||
* smooth shadow (because sample distribution is quite non-uniform) but is enough
|
||||
* in practice.
|
||||
**/
|
||||
*/
|
||||
/* NOTE: this has implication for spotlight rendering optimization
|
||||
* (see EEVEE_shadows_draw_cubemap). */
|
||||
float angular_texel_size = 2.0f * DEG2RADF(90) / (float)linfo->shadow_cube_size;
|
||||
|
|
|
@ -207,7 +207,7 @@ int EEVEE_temporal_sampling_init(EEVEE_ViewLayerData *UNUSED(sldata), EEVEE_Data
|
|||
/**
|
||||
* Reset for each "redraw". When rendering using ogl render,
|
||||
* we accumulate the redraw inside the drawing loop in eevee_draw_scene().
|
||||
**/
|
||||
*/
|
||||
if (DRW_state_is_opengl_render()) {
|
||||
effects->taa_render_sample = 1;
|
||||
}
|
||||
|
|
|
@ -73,7 +73,7 @@ bool neighbor_affect_this_tile(ivec2 offset, vec2 velocity)
|
|||
* identical or both have opposite signs relative to
|
||||
* offset. If the offset coordinate is zero then
|
||||
* velocity is irrelevant.
|
||||
**/
|
||||
*/
|
||||
vec2 point = sign(offset * velocity);
|
||||
|
||||
float dist = (point.x + point.y);
|
||||
|
@ -96,7 +96,7 @@ bool neighbor_affect_this_tile(ivec2 offset, vec2 velocity)
|
|||
* |____|____|____|
|
||||
* | | | |
|
||||
* |____|____|____|
|
||||
**/
|
||||
*/
|
||||
return (abs(dist) == displacement);
|
||||
}
|
||||
|
||||
|
@ -114,7 +114,7 @@ bool neighbor_affect_this_tile(ivec2 offset, vec2 velocity)
|
|||
* |___/|////|____|
|
||||
* | //|////| | <--- This tile can't possibly be affected by the center one
|
||||
* |_///|///_|____|
|
||||
**/
|
||||
*/
|
||||
void main()
|
||||
{
|
||||
vec4 max_motion = vec4(0.0);
|
||||
|
|
|
@ -175,7 +175,7 @@ static MaterialGPencilStyle *gpencil_viewport_material_overrides(GPENCIL_Private
|
|||
* Creates a linked list of material pool containing all materials assigned for a given object.
|
||||
* We merge the material pools together if object does not contain a huge amount of materials.
|
||||
* Also return an offset to the first material of the object in the ubo.
|
||||
**/
|
||||
*/
|
||||
GPENCIL_MaterialPool *gpencil_material_pool_create(GPENCIL_PrivateData *pd, Object *ob, int *ofs)
|
||||
{
|
||||
GPENCIL_MaterialPool *matpool = pd->last_material_pool;
|
||||
|
@ -424,7 +424,7 @@ void gpencil_light_pool_populate(GPENCIL_LightPool *lightpool, Object *ob)
|
|||
|
||||
/**
|
||||
* Creates a single pool containing all lights assigned (light linked) for a given object.
|
||||
**/
|
||||
*/
|
||||
GPENCIL_LightPool *gpencil_light_pool_create(GPENCIL_PrivateData *pd, Object *UNUSED(ob))
|
||||
{
|
||||
GPENCIL_LightPool *lightpool = pd->last_light_pool;
|
||||
|
|
|
@ -128,7 +128,7 @@ void blend_mode_output(
|
|||
* rtn = 1 - 2 (1 - dst * (1 - src) - src);
|
||||
* rtn = 1 - 2 + dst * (2 - 2 * src) + 2 * src;
|
||||
* rtn = (- 1 + 2 * src) + dst * (2 - 2 * src);
|
||||
**/
|
||||
*/
|
||||
color = mix(vec4(0.5), color, color.a * opacity);
|
||||
vec4 s = step(-0.5, -color);
|
||||
frag_revealage = frag_color = 2.0 * s + 2.0 * color * (1.0 - s * 2.0);
|
||||
|
@ -363,7 +363,7 @@ void color_output(vec4 stroke_col, vec4 vert_col, float vert_strength, float mix
|
|||
* finalColorAdd is how much of the mixed color to add.
|
||||
* Note that we never add alpha. This is to keep the texture act as a stencil.
|
||||
* We do however, modulate the alpha (reduce it).
|
||||
**/
|
||||
*/
|
||||
/* We add the mixed color. This is 100% mix (no texture visible). */
|
||||
finalColorMul = vec4(mixed_col.aaa, mixed_col.a);
|
||||
finalColorAdd = vec4(mixed_col.rgb * mixed_col.a, 0.0);
|
||||
|
|
|
@ -480,7 +480,7 @@ void DRW_shgroup_state_disable(DRWShadingGroup *shgroup, DRWState state);
|
|||
* - (compare_mask & reference) is what is tested against (compare_mask & stencil_value)
|
||||
* stencil_value being the value stored in the stencil buffer.
|
||||
* - (write-mask & reference) is what gets written if the test condition is fulfilled.
|
||||
**/
|
||||
*/
|
||||
void DRW_shgroup_stencil_set(DRWShadingGroup *shgroup,
|
||||
uint write_mask,
|
||||
uint reference,
|
||||
|
|
|
@ -429,7 +429,7 @@ struct DRWView {
|
|||
* We lose a bit of memory by allocating more than what we need
|
||||
* but it's counterbalanced by not needing the linked-list pointers
|
||||
* for each item.
|
||||
**/
|
||||
*/
|
||||
|
||||
typedef struct DRWUniformChunk {
|
||||
struct DRWUniformChunk *next; /* single-linked list */
|
||||
|
@ -480,7 +480,7 @@ typedef struct DRWDebugSphere {
|
|||
|
||||
/* ------------- DRAW MANAGER ------------ */
|
||||
|
||||
#define DST_MAX_SLOTS 64 /* Cannot be changed without modifying RST.bound_tex_slots */
|
||||
#define DST_MAX_SLOTS 64 /* Cannot be changed without modifying RST.bound_tex_slots */
|
||||
#define MAX_CLIP_PLANES 6 /* GL_MAX_CLIP_PLANES is at least 6 */
|
||||
#define STENCIL_UNDEFINED 256
|
||||
#define DRW_DRAWLIST_LEN 256
|
||||
|
|
|
@ -514,10 +514,10 @@ static void drw_call_obinfos_init(DRWObjectInfos *ob_infos, Object *ob)
|
|||
drw_call_calc_orco(ob, ob_infos->orcotexfac);
|
||||
/* Random float value. */
|
||||
uint random = (DST.dupli_source) ?
|
||||
DST.dupli_source->random_id :
|
||||
/* TODO(fclem): this is rather costly to do at runtime. Maybe we can
|
||||
* put it in ob->runtime and make depsgraph ensure it is up to date. */
|
||||
BLI_hash_int_2d(BLI_hash_string(ob->id.name + 2), 0);
|
||||
DST.dupli_source->random_id :
|
||||
/* TODO(fclem): this is rather costly to do at runtime. Maybe we can
|
||||
* put it in ob->runtime and make depsgraph ensure it is up to date. */
|
||||
BLI_hash_int_2d(BLI_hash_string(ob->id.name + 2), 0);
|
||||
ob_infos->ob_random = random * (1.0f / (float)0xFFFFFFFF);
|
||||
/* Object State. */
|
||||
ob_infos->ob_flag = 1.0f; /* Required to have a correct sign */
|
||||
|
@ -1773,7 +1773,7 @@ DRWView *DRW_view_create_sub(const DRWView *parent_view,
|
|||
* DRWView Update:
|
||||
* This is meant to be done on existing views when rendering in a loop and there is no
|
||||
* need to allocate more DRWViews.
|
||||
**/
|
||||
*/
|
||||
|
||||
/* Update matrices of a view created with DRW_view_create_sub. */
|
||||
void DRW_view_update_sub(DRWView *view, const float viewmat[4][4], const float winmat[4][4])
|
||||
|
|
|
@ -266,7 +266,7 @@ static void drw_stencil_state_set(uint write_mask, uint reference, uint compare_
|
|||
* - (compare_mask & reference) is what is tested against (compare_mask & stencil_value)
|
||||
* stencil_value being the value stored in the stencil buffer.
|
||||
* - (write-mask & reference) is what gets written if the test condition is fulfilled.
|
||||
**/
|
||||
*/
|
||||
GPU_stencil_write_mask_set(write_mask);
|
||||
GPU_stencil_reference_set(reference);
|
||||
GPU_stencil_compare_mask_set(compare_mask);
|
||||
|
|
|
@ -183,7 +183,7 @@ uniform mat4 ModelMatrixInverse;
|
|||
* Knowing that the view matrix is orthogonal, the transpose is also the inverse.
|
||||
* Note: This is only valid because we are only using the mat3 of the ViewMatrixInverse.
|
||||
* ViewMatrix * transpose(ModelMatrixInverse)
|
||||
**/
|
||||
*/
|
||||
#define NormalMatrix transpose(mat3(ModelMatrixInverse))
|
||||
#define NormalMatrixInverse transpose(mat3(ModelMatrix))
|
||||
|
||||
|
|
|
@ -1256,7 +1256,7 @@ void ED_sequencer_special_preview_clear(void)
|
|||
*
|
||||
* TODO: do not rely on such hack and just update the \a ibuf outside of
|
||||
* the UI drawing code.
|
||||
**/
|
||||
*/
|
||||
ImBuf *sequencer_ibuf_get(struct Main *bmain,
|
||||
ARegion *region,
|
||||
struct Depsgraph *depsgraph,
|
||||
|
|
|
@ -76,7 +76,7 @@ extern "C" {
|
|||
* IMPORTANT: Do not allocate manually as the real struct is bigger (i.e: GLBatch). This is only
|
||||
* the common and "public" part of the struct. Use the provided allocator.
|
||||
* TODO(fclem): Make the content of this struct hidden and expose getters/setters.
|
||||
**/
|
||||
*/
|
||||
typedef struct GPUBatch {
|
||||
/** verts[0] is required, others can be NULL */
|
||||
GPUVertBuf *verts[GPU_BATCH_VBO_MAX_LEN];
|
||||
|
|
|
@ -60,7 +60,7 @@ typedef enum {
|
|||
* TODO Improve error checking by validating that the shader is suited for this primitive type.
|
||||
* GPUPrimClass GPU_primtype_class(GPUPrimType);
|
||||
* bool GPU_primtype_belongs_to_class(GPUPrimType, GPUPrimClass);
|
||||
**/
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
|
@ -37,8 +37,9 @@ namespace gpu {
|
|||
|
||||
/**
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
* NOTE: Extends GPUBatch as we still needs to expose some of the internals to the outside C code.
|
||||
**/
|
||||
*
|
||||
* \note Extends #GPUBatch as we still needs to expose some of the internals to the outside C code.
|
||||
*/
|
||||
class Batch : public GPUBatch {
|
||||
public:
|
||||
Batch(){};
|
||||
|
|
|
@ -33,7 +33,7 @@ namespace blender::gpu {
|
|||
* Only add workarounds here if they are common to all implementation or
|
||||
* if you need access to it outside of the GPU module.
|
||||
* Same goes for capabilities (i.e.: texture size)
|
||||
**/
|
||||
*/
|
||||
struct GPUCapabilities {
|
||||
int max_texture_size = 0;
|
||||
int max_texture_layers = 0;
|
||||
|
|
|
@ -33,7 +33,7 @@ namespace gpu {
|
|||
/**
|
||||
* Implementation of Multi Draw Indirect.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class DrawList {
|
||||
public:
|
||||
virtual ~DrawList(){};
|
||||
|
|
|
@ -44,9 +44,9 @@ static inline size_t to_bytesize(GPUIndexBufType type)
|
|||
/**
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
*
|
||||
* NOTE: IndexBuf does not hold any GPUPrimType. This is because it can be interpreted
|
||||
* differently by multiple batches.
|
||||
**/
|
||||
* \note #IndexBuf does not hold any #GPUPrimType.
|
||||
* This is because it can be interpreted differently by multiple batches.
|
||||
*/
|
||||
class IndexBuf {
|
||||
protected:
|
||||
/** Type of indices used inside this buffer. */
|
||||
|
|
|
@ -48,7 +48,7 @@ typedef struct ShaderInput {
|
|||
/**
|
||||
* Implementation of Shader interface.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class ShaderInterface {
|
||||
/* TODO(fclem): should be protected. */
|
||||
public:
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace gpu {
|
|||
/**
|
||||
* Implementation of shader compilation and uniforms handling.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class Shader {
|
||||
public:
|
||||
/** Uniform & attribute locations for shader. */
|
||||
|
|
|
@ -148,7 +148,7 @@ inline GPUStateMutable operator~(const GPUStateMutable &a)
|
|||
/**
|
||||
* State manager keeping track of the draw state and applying it before drawing.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class StateManager {
|
||||
public:
|
||||
GPUState state;
|
||||
|
|
|
@ -71,7 +71,7 @@ ENUM_OPERATORS(eGPUTextureType, GPU_TEXTURE_CUBE_ARRAY)
|
|||
/**
|
||||
* Implementation of Textures.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class Texture {
|
||||
public:
|
||||
/** Internal Sampler state. */
|
||||
|
|
|
@ -38,7 +38,7 @@ namespace gpu {
|
|||
/**
|
||||
* Implementation of Uniform Buffers.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class UniformBuf {
|
||||
protected:
|
||||
/** Data size in bytes. */
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace blender::gpu {
|
|||
/**
|
||||
* Implementation of Vertex Buffers.
|
||||
* Base class which is then specialized for each implementation (GL, VK, ...).
|
||||
**/
|
||||
*/
|
||||
class VertBuf {
|
||||
public:
|
||||
static size_t memory_usage;
|
||||
|
|
|
@ -238,7 +238,7 @@ GLuint GLVaoCache::base_instance_vao_get(GPUBatch *batch, int i_first)
|
|||
/**
|
||||
* There seems to be a nasty bug when drawing using the same VAO reconfiguring (T71147).
|
||||
* We just use a throwaway VAO for that. Note that this is likely to degrade performance.
|
||||
**/
|
||||
*/
|
||||
#ifdef __APPLE__
|
||||
glDeleteVertexArrays(1, &vao_base_instance_);
|
||||
vao_base_instance_ = 0;
|
||||
|
|
|
@ -41,7 +41,7 @@ namespace gpu {
|
|||
|
||||
/**
|
||||
* Implementation of Multi Draw Indirect using OpenGL.
|
||||
**/
|
||||
*/
|
||||
class GLDrawList : public DrawList {
|
||||
public:
|
||||
GLDrawList(int length);
|
||||
|
|
|
@ -37,7 +37,7 @@ class GLStateManager;
|
|||
|
||||
/**
|
||||
* Implementation of FrameBuffer object using OpenGL.
|
||||
**/
|
||||
*/
|
||||
class GLFrameBuffer : public FrameBuffer {
|
||||
/* For debugging purpose. */
|
||||
friend class GLTexture;
|
||||
|
@ -61,7 +61,7 @@ class GLFrameBuffer : public FrameBuffer {
|
|||
public:
|
||||
/**
|
||||
* Create a conventional framebuffer to attach texture to.
|
||||
**/
|
||||
*/
|
||||
GLFrameBuffer(const char *name);
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ class GLFrameBuffer : public FrameBuffer {
|
|||
* \param fbo: The (optional) already created object for some implementation. Default is 0.
|
||||
* \param w: Buffer width.
|
||||
* \param h: Buffer height.
|
||||
**/
|
||||
*/
|
||||
GLFrameBuffer(const char *name, GLContext *ctx, GLenum target, GLuint fbo, int w, int h);
|
||||
|
||||
~GLFrameBuffer();
|
||||
|
|
|
@ -34,7 +34,7 @@ namespace gpu {
|
|||
|
||||
/**
|
||||
* Implementation of shader compilation and uniforms handling using OpenGL.
|
||||
**/
|
||||
*/
|
||||
class GLShader : public Shader {
|
||||
private:
|
||||
/** Handle for full program (links shader stages below). */
|
||||
|
|
|
@ -42,7 +42,7 @@ class GLVaoCache;
|
|||
|
||||
/**
|
||||
* Implementation of Shader interface using OpenGL.
|
||||
**/
|
||||
*/
|
||||
class GLShaderInterface : public ShaderInterface {
|
||||
private:
|
||||
/** Reference to VaoCaches using this interface */
|
||||
|
|
|
@ -358,7 +358,7 @@ void GLStateManager::set_blend(const eGPUBlend value)
|
|||
* DST is frame-buffer color.
|
||||
* final.rgb = SRC.rgb * src_rgb + DST.rgb * dst_rgb;
|
||||
* final.a = SRC.a * src_alpha + DST.a * dst_alpha;
|
||||
**/
|
||||
*/
|
||||
GLenum src_rgb, src_alpha, dst_rgb, dst_alpha;
|
||||
switch (value) {
|
||||
default:
|
||||
|
|
|
@ -39,7 +39,7 @@ class GLTexture;
|
|||
/**
|
||||
* State manager keeping track of the draw state and applying it before drawing.
|
||||
* Opengl Implementation.
|
||||
**/
|
||||
*/
|
||||
class GLStateManager : public StateManager {
|
||||
public:
|
||||
/** Anothter reference to the active framebuffer. */
|
||||
|
|
|
@ -489,7 +489,7 @@ void GLTexture::samplers_init()
|
|||
* - GL_TEXTURE_MIN_LOD is -1000.
|
||||
* - GL_TEXTURE_MAX_LOD is 1000.
|
||||
* - GL_TEXTURE_LOD_BIAS is 0.0f.
|
||||
**/
|
||||
*/
|
||||
|
||||
char sampler_name[128] = "\0\0";
|
||||
SNPRINTF(sampler_name,
|
||||
|
|
|
@ -34,7 +34,7 @@ namespace gpu {
|
|||
|
||||
/**
|
||||
* Implementation of Uniform Buffers using OpenGL.
|
||||
**/
|
||||
*/
|
||||
class GLUniformBuf : public UniformBuf {
|
||||
private:
|
||||
/** Slot to which this UBO is currently bound. -1 if not bound. */
|
||||
|
|
|
@ -86,8 +86,8 @@ static bool IMB_gpu_get_compressed_format(const ImBuf *ibuf, eGPUTextureFormat *
|
|||
|
||||
/**
|
||||
* Apply colormanagement and scale buffer if needed.
|
||||
* *r_freedata is set to true if the returned buffer need to be manually freed.
|
||||
**/
|
||||
* `*r_freedata` is set to true if the returned buffer need to be manually freed.
|
||||
*/
|
||||
static void *imb_gpu_get_data(const ImBuf *ibuf,
|
||||
const bool do_rescale,
|
||||
const int rescale_size[2],
|
||||
|
|
|
@ -96,7 +96,7 @@ static float point_weight_influence_get(const float maximum_distance,
|
|||
*
|
||||
* For each index in the weight array add a weight based on the proximity the
|
||||
* corresponding point has with its neighbors.
|
||||
**/
|
||||
*/
|
||||
static void points_distance_weight_calculate(Vector<float> *weights,
|
||||
const size_t point_id,
|
||||
const float3 *input_points,
|
||||
|
|
Loading…
Reference in New Issue