initial commit
This commit is contained in:
commit
5a234e06f1
|
@ -0,0 +1,12 @@
|
|||
@echo off
|
||||
|
||||
echo ~~~~ starting build ~~~~~
|
||||
|
||||
REM call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat"
|
||||
|
||||
REM INCLUDES
|
||||
set sdl_inc_path="D:\dev\libraries\SDL2-devel-2.24.2-VC\SDL2-2.24.2\include"
|
||||
set sdl_lib_path="D:\dev\libraries\SDL2-devel-2.24.2-VC\SDL2-2.24.2\lib\x64"
|
||||
set output_dir="build\"
|
||||
|
||||
cl /nologo /Zi /Fd"build/" /Fo"build/" /Fe"build/app.exe" /I %sdl_inc_path% *.cpp SDL2.lib SDL2main.lib shell32.lib /link /SUBSYSTEM:CONSOLE /LIBPATH:%sdl_lib_path%
|
Binary file not shown.
|
@ -0,0 +1,30 @@
|
|||
#include "SDL.h"
|
||||
#include <stdio.h>
|
||||
|
||||
SDL_Window *window;
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
if (SDL_Init(SDL_INIT_EVERYTHING) != 0) {
|
||||
fprintf(stderr, "there was an error attempting to initilizer SDL");
|
||||
}
|
||||
|
||||
// create a display mode
|
||||
SDL_DisplayMode display_mode;
|
||||
|
||||
// and store in it current display mode settings
|
||||
SDL_GetCurrentDisplayMode(0, &display_mode);
|
||||
|
||||
// create an sdl window object
|
||||
window = SDL_CreateWindow(
|
||||
"Cool new window",
|
||||
SDL_WINDOWPOS_CENTERED,
|
||||
SDL_WINDOWPOS_CENTERED,
|
||||
display_mode.w, display_mode.h,
|
||||
SDL_WINDOW_RESIZABLE
|
||||
);
|
||||
|
||||
printf("hello there");
|
||||
|
||||
return(0);
|
||||
}
|
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
"folders":
|
||||
[
|
||||
{
|
||||
"path": "."
|
||||
},
|
||||
{
|
||||
"name": "SDL",
|
||||
"path": "D:/dev/libraries/SDL2-devel-2.24.2-VC/SDL2-2.24.2/include"
|
||||
}
|
||||
],
|
||||
|
||||
"build_systems":
|
||||
[
|
||||
{
|
||||
"name": "build.bat",
|
||||
"shell_cmd": "build.bat",
|
||||
"selector": "source.c++",
|
||||
"working_dir": "$project_path",
|
||||
"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue