mirror of
https://github.com/nicbarker/clay.git
synced 2025-09-18 20:46:17 +00:00
swap round for floor to appease compiler
This commit is contained in:
parent
e93a83812e
commit
b2ffb2f0e5
|
@ -88,10 +88,10 @@ void Clay_Console_Render(Clay_RenderCommandArray renderCommands, int width, int
|
||||||
for (int j = 0; j < renderCommands.length; j++) {
|
for (int j = 0; j < renderCommands.length; j++) {
|
||||||
Clay_RenderCommand *renderCommand = Clay_RenderCommandArray_Get(&renderCommands, j);
|
Clay_RenderCommand *renderCommand = Clay_RenderCommandArray_Get(&renderCommands, j);
|
||||||
Clay_BoundingBox boundingBox = (Clay_BoundingBox) {
|
Clay_BoundingBox boundingBox = (Clay_BoundingBox) {
|
||||||
.x = roundf((renderCommand->boundingBox.x / columnWidth)),
|
.x = floorf((renderCommand->boundingBox.x / columnWidth) + 0.5),
|
||||||
.y = roundf((renderCommand->boundingBox.y / columnWidth)),
|
.y = floorf((renderCommand->boundingBox.y / columnWidth) + 0.5),
|
||||||
.width = roundf((renderCommand->boundingBox.width / columnWidth)),
|
.width = floorf((renderCommand->boundingBox.width / columnWidth) + 0.5),
|
||||||
.height = roundf((renderCommand->boundingBox.height / columnWidth)),
|
.height = floorf((renderCommand->boundingBox.height / columnWidth) + 0.5),
|
||||||
};
|
};
|
||||||
switch (renderCommand->commandType) {
|
switch (renderCommand->commandType) {
|
||||||
case CLAY_RENDER_COMMAND_TYPE_TEXT: {
|
case CLAY_RENDER_COMMAND_TYPE_TEXT: {
|
||||||
|
|
Loading…
Reference in a new issue