RI_functions.h 1003 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #ifndef RI_FUNCTIONS_H
  2. #define RI_FUNCTIONS_H
  3. #include "RI_types.h"
  4. // returns the RI_context
  5. RI_context *RI_get_context();
  6. // initilizes RasterIver
  7. // returns completion code (0: fine, 1: error)
  8. int RI_init();
  9. // ticks RasterIver (updated window, check for events, renders scene, etc)
  10. void RI_tick();
  11. // renders a scene to the screen
  12. void RI_render(RI_scene *scene);
  13. // loads an OBJ file into memory as a mesh
  14. RI_mesh *RI_load_mesh(char* filename);
  15. // allocates and returns a pointer to a new scene
  16. RI_scene *RI_new_scene();
  17. // allocates and returns a pointer to a new actor
  18. RI_actor *RI_new_actor();
  19. // allocates and returns a pointer to a new material
  20. RI_material *RI_new_material();
  21. // allocates and returns a pointer to a new texture
  22. RI_texture *RI_new_texture(int width, int height);
  23. // loads an image file as a texture
  24. RI_texture* RI_load_image(char* filename);
  25. // loads an image file as an animated texture
  26. RI_texture* RI_load_animation(char* filename, uint16_t frame_count);
  27. #endif