remove unneeded boilerplate from examples
This commit is contained in:
parent
a2ce1e13ca
commit
678b89e9b2
@ -6,10 +6,7 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
srvInit(); // Needed
|
||||
aptInit(); // Needed
|
||||
gfxInitDefault(); // Init graphic stuff
|
||||
hidInit(NULL); // For input (buttons, touchscreen...)
|
||||
|
||||
|
||||
// We need these 2 buffers for APT_DoAppJump() later. They can be smaller too
|
||||
@ -46,11 +43,7 @@ int main()
|
||||
}
|
||||
|
||||
|
||||
// Deinit everything before the app process get's terminated
|
||||
hidExit();
|
||||
gfxExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -13,10 +13,7 @@ int main()
|
||||
u8 control=0x40;
|
||||
u32 audio_initialized = 0;
|
||||
|
||||
srvInit();
|
||||
aptInit();
|
||||
gfxInitDefault();
|
||||
hidInit(NULL);
|
||||
|
||||
if(CSND_initialize(NULL)==0)audio_initialized = 1;
|
||||
|
||||
@ -85,10 +82,7 @@ int main()
|
||||
free(sharedmem);
|
||||
linearFree(audiobuf);
|
||||
|
||||
hidExit();
|
||||
gfxExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -189,11 +189,8 @@ void renderFrame()
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
//setup services
|
||||
srvInit();
|
||||
aptInit();
|
||||
|
||||
gfxInitDefault();
|
||||
hidInit(NULL);
|
||||
|
||||
//initialize GPU
|
||||
GPU_Init(NULL);
|
||||
@ -321,9 +318,6 @@ int main(int argc, char** argv)
|
||||
}
|
||||
|
||||
gsExit();
|
||||
hidExit();
|
||||
gfxExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
@ -17,11 +17,7 @@
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
gfxInitDefault();
|
||||
hidInit(NULL);
|
||||
|
||||
//Initialize console on top screen. Using NULL as the second argument tells the console library to use the internal console structure as current one
|
||||
consoleInit(GFX_TOP, NULL);
|
||||
@ -54,10 +50,6 @@ int main(int argc, char **argv)
|
||||
gspWaitForVBlank();
|
||||
}
|
||||
|
||||
// Exit services
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
@ -87,10 +87,6 @@ int main()
|
||||
Result ret=0;
|
||||
httpcContext context;
|
||||
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
hidInit(NULL);
|
||||
gfxInitDefault();
|
||||
//gfxSet3D(true); // uncomment if using stereoscopic 3D
|
||||
httpcInit();
|
||||
@ -123,9 +119,6 @@ int main()
|
||||
// Exit services
|
||||
httpcExit();
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -4,10 +4,6 @@ int main()
|
||||
{
|
||||
u32 val, i;
|
||||
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
hidInit(NULL);
|
||||
gfxInitDefault();
|
||||
//gfxSet3D(true); // uncomment if using stereoscopic 3D
|
||||
|
||||
@ -42,9 +38,6 @@ int main()
|
||||
|
||||
// Exit services
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -106,13 +106,7 @@ void draw_startup()
|
||||
|
||||
int main()
|
||||
{
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
hidInit(NULL);
|
||||
gfxInitDefault();
|
||||
fsInit();
|
||||
sdmcInit();
|
||||
//gfxSet3D(true); // uncomment if using stereoscopic 3D
|
||||
|
||||
memset(logstring, 0, 256);
|
||||
@ -143,13 +137,7 @@ int main()
|
||||
if(inaddr)linearFree(inaddr);
|
||||
if(outaddr)linearFree(outaddr);
|
||||
|
||||
// Exit services
|
||||
sdmcExit();
|
||||
fsExit();
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -11,10 +11,6 @@ int main()
|
||||
qtmHeadtrackingInfo qtminfo;
|
||||
u32 colors[4] = {0x0000FF, 0x00FF00, 0xFF0000, 0xFFFFFF};
|
||||
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
hidInit(NULL);
|
||||
gfxInitDefault();
|
||||
//gfxSet3D(true); // uncomment if using stereoscopic 3D
|
||||
|
||||
@ -84,9 +80,6 @@ int main()
|
||||
// Exit services
|
||||
qtmExit();
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -4,10 +4,6 @@
|
||||
|
||||
int main()
|
||||
{
|
||||
// Initialize services
|
||||
srvInit();
|
||||
aptInit();
|
||||
hidInit(NULL);
|
||||
gfxInitDefault();
|
||||
//gfxSet3D(true); // uncomment if using stereoscopic 3D
|
||||
|
||||
@ -36,10 +32,6 @@ int main()
|
||||
gfxSwapBuffers();
|
||||
}
|
||||
|
||||
// Exit services
|
||||
gfxExit();
|
||||
hidExit();
|
||||
aptExit();
|
||||
srvExit();
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user