Starter project for SDL2.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
613 B

  1. #include "IZ_video.h"
  2. void IZ_SaveVideoConfig(IZ_VideoConfig* config) {
  3. char config_path[128];
  4. IZ_GetConfigPath(config_path);
  5. ini_putl("Video", "Width", config->width, config_path);
  6. ini_putl("Video", "Height", config->height, config_path);
  7. ini_putl("Video", "MaxFps", config->max_fps, config_path);
  8. }
  9. void IZ_LoadVideoConfig(IZ_VideoConfig* config) {
  10. char config_path[128];
  11. IZ_GetConfigPath(config_path);
  12. config->width = ini_getl("Video", "Width", 640l, config_path);
  13. config->height = ini_getl("Video", "Height", 480l, config_path);
  14. config->max_fps = ini_getl("Video", "MaxFps", 30, config_path);
  15. }