mirror of https://github.com/MLXXXp/Arduboy2.git
Merge branch 'master' into remove-unncessary-limits-include
This commit is contained in:
commit
d52f71cc0b
|
|
@ -8,6 +8,24 @@
|
||||||
#include "ab_logo.c"
|
#include "ab_logo.c"
|
||||||
#include "glcdfont.c"
|
#include "glcdfont.c"
|
||||||
|
|
||||||
|
//================================
|
||||||
|
//========== class Rect ==========
|
||||||
|
//================================
|
||||||
|
|
||||||
|
Rect::Rect(int16_t x, int16_t y, uint8_t width, uint8_t height)
|
||||||
|
: x(x), y(y), width(width), height(height)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
//=================================
|
||||||
|
//========== class Point ==========
|
||||||
|
//=================================
|
||||||
|
|
||||||
|
Point::Point(int16_t x, int16_t y)
|
||||||
|
: x(x), y(y)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
//========================================
|
//========================================
|
||||||
//========== class Arduboy2Base ==========
|
//========== class Arduboy2Base ==========
|
||||||
//========================================
|
//========================================
|
||||||
|
|
|
||||||
|
|
@ -103,6 +103,10 @@ struct Rect
|
||||||
int16_t y; /**< The Y coordinate of the top left corner */
|
int16_t y; /**< The Y coordinate of the top left corner */
|
||||||
uint8_t width; /**< The width of the rectangle */
|
uint8_t width; /**< The width of the rectangle */
|
||||||
uint8_t height; /**< The height of the rectangle */
|
uint8_t height; /**< The height of the rectangle */
|
||||||
|
|
||||||
|
Rect() = default; /**< The default constructor of the point */
|
||||||
|
|
||||||
|
Rect(int16_t x, int16_t y, uint8_t width, uint8_t height); /**< The fully initialising constructor of the point */
|
||||||
};
|
};
|
||||||
|
|
||||||
/** \brief
|
/** \brief
|
||||||
|
|
@ -117,6 +121,10 @@ struct Point
|
||||||
{
|
{
|
||||||
int16_t x; /**< The X coordinate of the point */
|
int16_t x; /**< The X coordinate of the point */
|
||||||
int16_t y; /**< The Y coordinate of the point */
|
int16_t y; /**< The Y coordinate of the point */
|
||||||
|
|
||||||
|
Point() = default; /**< The default constructor of the point */
|
||||||
|
|
||||||
|
Point(int16_t x, int16_t y); /**< The fully initialising constructor of the point */
|
||||||
};
|
};
|
||||||
|
|
||||||
//==================================
|
//==================================
|
||||||
|
|
@ -1018,7 +1026,7 @@ class Arduboy2Base : public Arduboy2Core
|
||||||
*
|
*
|
||||||
* \see Point Rect
|
* \see Point Rect
|
||||||
*/
|
*/
|
||||||
bool collide(Point point, Rect rect);
|
static bool collide(Point point, Rect rect);
|
||||||
|
|
||||||
/** \brief
|
/** \brief
|
||||||
* Test if a rectangle is intersecting with another rectangle.
|
* Test if a rectangle is intersecting with another rectangle.
|
||||||
|
|
@ -1035,7 +1043,7 @@ class Arduboy2Base : public Arduboy2Core
|
||||||
*
|
*
|
||||||
* \see Rect
|
* \see Rect
|
||||||
*/
|
*/
|
||||||
bool collide(Rect rect1, Rect rect2);
|
static bool collide(Rect rect1, Rect rect2);
|
||||||
|
|
||||||
/** \brief
|
/** \brief
|
||||||
* Read the unit ID from system EEPROM.
|
* Read the unit ID from system EEPROM.
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,8 @@
|
||||||
|
|
||||||
#include "Arduboy2Core.h"
|
#include "Arduboy2Core.h"
|
||||||
|
|
||||||
|
#include <avr/wdt.h>
|
||||||
|
|
||||||
const uint8_t PROGMEM lcdBootProgram[] = {
|
const uint8_t PROGMEM lcdBootProgram[] = {
|
||||||
// boot defaults are commented out but left here in case they
|
// boot defaults are commented out but left here in case they
|
||||||
// might prove useful for reference
|
// might prove useful for reference
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,6 @@
|
||||||
#include <Arduino.h>
|
#include <Arduino.h>
|
||||||
#include <avr/power.h>
|
#include <avr/power.h>
|
||||||
#include <avr/sleep.h>
|
#include <avr/sleep.h>
|
||||||
#include <avr/wdt.h>
|
|
||||||
|
|
||||||
|
|
||||||
// main hardware compile flags
|
// main hardware compile flags
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue