mirror of
https://github.com/love2d/love.git
synced 2026-08-20 12:40:20 +02:00
Moved the appveyor script to a subfolder and updated it to properly choose Visual Studio 2012 and to create a post-build zip file.
This commit is contained in:
@@ -25,12 +25,22 @@ install:
|
|||||||
- move love libs\love
|
- move love libs\love
|
||||||
|
|
||||||
before_build:
|
before_build:
|
||||||
- cmake -H. -Bbuild
|
- cmake -G "Visual Studio 12" -H. -Bbuild
|
||||||
|
|
||||||
build_script:
|
build_script:
|
||||||
- cmake --build build --target love/love --config Release
|
- cmake --build build --target love/love --config Release
|
||||||
|
|
||||||
|
after_build:
|
||||||
|
# TODO: Find the C++ and C runtime .dll's and zip them.
|
||||||
|
- 7z a love.zip %APPVEYOR_BUILD_FOLDER%\build\love\Release\*.dll
|
||||||
|
- 7z a love.zip %APPVEYOR_BUILD_FOLDER%\build\love\Release\love.exe
|
||||||
|
- 7z a love.zip %APPVEYOR_BUILD_FOLDER%\build\love\changes.txt
|
||||||
|
- 7z a love.zip %APPVEYOR_BUILD_FOLDER%\build\love\license.txt
|
||||||
|
|
||||||
before_test:
|
before_test:
|
||||||
|
|
||||||
|
|
||||||
test_script:
|
test_script:
|
||||||
|
|
||||||
|
|
||||||
|
artifacts:
|
||||||
|
- path: love.zip
|
||||||
@@ -92,7 +92,7 @@ void OpenGL::setupContext()
|
|||||||
|
|
||||||
GLint maxvertexattribs = 1;
|
GLint maxvertexattribs = 1;
|
||||||
glGetIntegerv(GL_MAX_VERTEX_ATTRIBS, &maxvertexattribs);
|
glGetIntegerv(GL_MAX_VERTEX_ATTRIBS, &maxvertexattribs);
|
||||||
state.enabledAttribArrays = 1u << uint32(maxvertexattribs - 1);
|
state.enabledAttribArrays = (uint32) ((1ull << uint32(maxvertexattribs)) - 1);
|
||||||
useVertexAttribArrays(0);
|
useVertexAttribArrays(0);
|
||||||
|
|
||||||
// Get the current viewport.
|
// Get the current viewport.
|
||||||
@@ -391,8 +391,8 @@ void OpenGL::useVertexAttribArrays(uint32 arraybits)
|
|||||||
state.enabledAttribArrays = arraybits;
|
state.enabledAttribArrays = arraybits;
|
||||||
|
|
||||||
// glDisableVertexAttribArray will make the constant value for a vertex
|
// glDisableVertexAttribArray will make the constant value for a vertex
|
||||||
// attribute undefined. We rely on the per-vertex color attribte being white
|
// attribute undefined. We rely on the per-vertex color attribute being
|
||||||
// when no per-vertex color is used, so we set it here.
|
// white when no per-vertex color is used, so we set it here.
|
||||||
// FIXME: Is there a better place to do this?
|
// FIXME: Is there a better place to do this?
|
||||||
if ((diff & ATTRIBFLAG_COLOR) && !(arraybits & ATTRIBFLAG_COLOR))
|
if ((diff & ATTRIBFLAG_COLOR) && !(arraybits & ATTRIBFLAG_COLOR))
|
||||||
glVertexAttrib4f(ATTRIB_COLOR, 1.0f, 1.0f, 1.0f, 1.0f);
|
glVertexAttrib4f(ATTRIB_COLOR, 1.0f, 1.0f, 1.0f, 1.0f);
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ static size_t vorbisRead(void *ptr /* ptr to the data that the vorbis files need
|
|||||||
if (actualSizeToRead)
|
if (actualSizeToRead)
|
||||||
{
|
{
|
||||||
// Copy the data from the start of the file PLUS how much we have already read in
|
// Copy the data from the start of the file PLUS how much we have already read in
|
||||||
memcpy(ptr, (char *)vorbisData->dataPtr + vorbisData->dataRead, actualSizeToRead);
|
memcpy(ptr, (const char *)vorbisData->dataPtr + vorbisData->dataRead, actualSizeToRead);
|
||||||
// Increase by how much we have read by
|
// Increase by how much we have read by
|
||||||
vorbisData->dataRead += (actualSizeToRead);
|
vorbisData->dataRead += (actualSizeToRead);
|
||||||
}
|
}
|
||||||
@@ -109,7 +109,7 @@ static int vorbisSeek(void *datasource /* ptr to the data that the vorbis files
|
|||||||
vorbisData->dataRead = vorbisData->dataSize+1;
|
vorbisData->dataRead = vorbisData->dataSize+1;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw love::Exception("Unknown seek command in vorbisSeek\n");
|
throw love::Exception("Unknown seek command in vorbisSeek");
|
||||||
break;
|
break;
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -143,7 +143,7 @@ VorbisDecoder::VorbisDecoder(Data *data, const std::string &ext, int bufferSize)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Initialize OGG file
|
// Initialize OGG file
|
||||||
oggFile.dataPtr = (char *) data->getData();
|
oggFile.dataPtr = (const char *) data->getData();
|
||||||
oggFile.dataSize = (int) data->getSize();
|
oggFile.dataSize = (int) data->getSize();
|
||||||
oggFile.dataRead = 0;
|
oggFile.dataRead = 0;
|
||||||
|
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ namespace lullaby
|
|||||||
// Struct for handling data
|
// Struct for handling data
|
||||||
struct SOggFile
|
struct SOggFile
|
||||||
{
|
{
|
||||||
char *dataPtr; // Pointer to the data in memory
|
const char *dataPtr; // Pointer to the data in memory
|
||||||
int dataSize; // Size of the data
|
int dataSize; // Size of the data
|
||||||
int dataRead; // How much we've read so far
|
int dataRead; // How much we've read so far
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user