[CHG] Use M_PI instead of custom macro for PI in two examples

This commit is contained in:
Crayon2000 2010-10-05 03:02:38 +00:00
parent 675bdbab96
commit 6f00bceb2f
2 changed files with 28 additions and 32 deletions

View file

@ -14,8 +14,6 @@
#include "gfx/font.h"
#include "gfx/ball.h"
#define PI 3.14159265358979323846F
extern GXRModeObj *rmode;
int main() {
@ -77,12 +75,12 @@ int main() {
spr+=0.1f;
t+=0.01f;
if(t>n*2*PI) {
if(t>n*2*M_PI) {
n++;
f+=0.01f;
}
if(f>2*PI) {
if(f>2*M_PI) {
f=0;
ff+=0.02f;
}

View file

@ -14,8 +14,6 @@
#include "gfx/logo.h"
#include "gfx/font.h"
#define PI 3.14159265358979323846F
extern GXRModeObj *rmode;
@ -175,12 +173,12 @@ int main() {
spr+=0.1f;
t+=0.01f;
if(t>n*2*PI) {
if(t>n*2*M_PI) {
n++;
f+=0.01f;
}
if(f>2*PI) {
if(f>2*M_PI) {
f=0;
ff+=0.02f;
}