logo

qmk_firmware

custom branch of QMK firmware git clone https://anongit.hacktivis.me/git/qmk_firmware.git

heart.h (2487B)


  1. /* Copyright 2020 ademey "MsMustard"
  2. *
  3. * This program is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #ifndef DISABLE_TERRAZZO_EFFECT_HEART
  17. TERRAZZO_EFFECT(HEART)
  18. # ifdef TERRAZZO_EFFECT_IMPLS
  19. static uint8_t heart_frames[4][105] = {
  20. {
  21. 0, 0, 0, 0, 0, 0, 0,
  22. 0, 0, 0, 0, 0, 0, 0,
  23. 0, 0, 0, 0, 0, 0, 0,
  24. 0, 0, 0, 0, 0, 0, 0,
  25. 0, 5, 5, 0, 5, 5, 0,
  26. 5, 0, 0, 5, 0, 0, 5,
  27. 5, 0, 0, 0, 0, 0, 5,
  28. 0, 5, 0, 0, 0, 5, 0,
  29. 0, 0, 5, 0, 5, 0, 0,
  30. 0, 0, 0, 5, 0, 0, 0,
  31. 0, 0, 0, 0, 0, 0, 0,
  32. 0, 0, 0, 0, 0, 0, 0,
  33. 0, 0, 0, 0, 0, 0, 0,
  34. 0, 0, 0, 0, 0, 0, 0,
  35. 0, 0, 0, 0, 0, 0, 0
  36. },
  37. {
  38. 0, 0, 0, 0, 0, 0, 0,
  39. 0, 0, 0, 0, 0, 0, 0,
  40. 0, 0, 0, 0, 0, 0, 0,
  41. 0, 0, 0, 0, 0, 0, 0,
  42. 0, 5, 5, 0, 5, 5, 0,
  43. 5, 5, 5, 5, 5, 5, 5,
  44. 5, 5, 5, 5, 5, 5, 5,
  45. 0, 5, 5, 5, 5, 5, 0,
  46. 0, 0, 5, 5, 5, 0, 0,
  47. 0, 0, 0, 5, 0, 0, 0,
  48. 0, 0, 0, 0, 0, 0, 0,
  49. 0, 0, 0, 0, 0, 0, 0,
  50. 0, 0, 0, 0, 0, 0, 0,
  51. 0, 0, 0, 0, 0, 0, 0,
  52. 0, 0, 0, 0, 0, 0, 0
  53. },
  54. {
  55. 0, 0, 0, 0, 0, 0, 0,
  56. 0, 0, 0, 0, 0, 0, 0,
  57. 0, 1, 1, 0, 1, 1, 0,
  58. 1, 0, 0, 5, 0, 0, 1,
  59. 0, 5, 5, 0, 5, 5, 0,
  60. 5, 5, 5, 5, 5, 5, 5,
  61. 5, 5, 5, 5, 5, 5, 5,
  62. 0, 5, 5, 5, 5, 5, 0,
  63. 0, 0, 5, 5, 5, 0, 0,
  64. 1, 0, 0, 5, 0, 0, 1,
  65. 0, 1, 0, 0, 0, 1, 0,
  66. 0, 0, 1, 0, 1, 0, 0,
  67. 0, 0, 0, 1, 0, 0, 0,
  68. 0, 0, 0, 0, 0, 0, 0,
  69. 0, 0, 0, 0, 0, 0, 0
  70. },
  71. {
  72. 0, 1, 1, 0, 1, 1, 0,
  73. 1, 0, 0, 1, 0, 0, 1,
  74. 0, 5, 5, 0, 5, 5, 0,
  75. 5, 0, 0, 5, 0, 0, 5,
  76. 0, 5, 5, 0, 5, 5, 0,
  77. 5, 5, 5, 5, 5, 5, 5,
  78. 5, 5, 5, 5, 5, 5, 5,
  79. 0, 5, 5, 5, 5, 5, 0,
  80. 0, 0, 5, 5, 5, 0, 0,
  81. 5, 0, 0, 5, 0, 0, 5,
  82. 0, 5, 0, 0, 0, 5, 0,
  83. 1, 0, 5, 0, 5, 0, 1,
  84. 0, 1, 0, 5, 0, 1, 0,
  85. 0, 0, 1, 0, 1, 0, 0,
  86. 0, 0, 0, 1, 0, 0, 0
  87. }
  88. };
  89. void HEART(uint8_t i, bool dir) {
  90. led_matrix_set_value_all(0);
  91. terrazzo_draw_at(0, 0, 7, 15, heart_frames[i % 4]);
  92. }
  93. # endif
  94. #endif