Browse Source

add list of FIXMEs, remove safeRatio()

render_group_fix
cinnaboot 5 years ago
parent
commit
e4a390773e
  1. 8
      examples/render_groups/main.cpp
  2. 5
      include/asset.h
  3. 10
      include/util.h

8
examples/render_groups/main.cpp

@ -192,7 +192,13 @@ main()
#endif
// NOTE: testing entity system with new asset structures
// FIXME: wtf is this?
// FIXME: remove mesh.h, mesh.cpp
// FIXME: need a debug shader that shows geometry and normals
// FIXME: remove platform_wait_for_vblank
// FIXME: make a test case for overflowing default array sizes, rg->assets
// rg_info->groups, render_group->enitities
// FIXME: look for glm::mat4 in structs, and replace with pointers
// FIXME: better shader abstraction, see below
shader_wrapper sw = { DEFAULT_SHADER, rs->default_shader, nullptr };
render_group* rg = rgAlloc(rs->render_groups, 64, sw);
entity* e =

5
include/asset.h

@ -9,7 +9,7 @@
#include "util_image.h"
// NOTE: wrapper tinygltf https://github.com/syoyo/tinygltf
// NOTE: wrapper for tinygltf https://github.com/syoyo/tinygltf
// https://github.com/KhronosGroup/glTF
struct mesh
@ -20,9 +20,6 @@ struct mesh
uint num_indices;
glm::vec3* vertices;
glm::vec3* normals;
// FIXME: will have to use vec2 here to be able to use memcpy
// this will break render_object::initGLFLoatBuffer logic which expects
// vec3
glm::vec2* texture_coords;
uint* indices;
glm::mat4* xform;

10
include/util.h

@ -41,16 +41,6 @@ struct v3f
real64 z;
};
inline real32
SafeRatio(real32 dividend, real32 divisor)
{
if (divisor == 0)
// TODO: log warning (don't require aixlog)
return 0;
else
return dividend / divisor;
}
inline int32
SafeTruncateToInt32(int64 val)
{

Loading…
Cancel
Save