Skip to content
Permalink
Browse files

GCC 8 fixes

  • Loading branch information
eile committed Nov 14, 2019
1 parent 523a535 commit b7da6bc5dd16e838ced9a7e72a9f3511e7525643
@@ -72,7 +72,7 @@ class Window

MessagePump* const messagePump;
};
}
} // namespace detail

Window::Window(NotifierInterface& parent, const WindowSettings& settings,
Display* xDisplay, const GLXEWContext* glxewContext,
@@ -96,7 +96,7 @@ static Bool WaitForNotify(Display*, XEvent* e, char* arg)
{
return (e->type == MapNotify) && (e->xmap.window == (::Window)arg);
}
}
} // namespace

bool Window::configInit()
{
@@ -632,7 +632,9 @@ void Window::setXDrawable(XID drawable)
default:
LBERROR << "Unknown drawable type " << drawableType << std::endl;
LBUNIMPLEMENTED;
/* fall-thru */
case OFF:
/* fall-thru */
case FBO:
LBASSERT(getPixelViewport().hasArea());
}
@@ -880,5 +882,5 @@ void Window::exitEventHandler()
delete _impl->glXEventHandler;
_impl->glXEventHandler = 0;
}
}
}
} // namespace glx
} // namespace eq
@@ -679,7 +679,7 @@ static void _computeHeadTransform(Matrix4f& result, const Matrix4f& xfm,
result.array[i + 3] = xfm.array[i + 3];
}
}
}
} // namespace

void Compound::_computePerspective(RenderContext& context,
const Vector3f& eye) const
@@ -739,6 +739,7 @@ Vector3f Compound::_getEyePosition(const Eye eye) const

default:
LBUNIMPLEMENTED;
/* fall-thru */
case EYE_CYCLOP:
return Vector3f();
}
@@ -995,7 +996,7 @@ VisitorResult _accept(C* compound, CompoundVisitor& visitor)
}
return result;
}
}
} // namespace

VisitorResult Compound::accept(CompoundVisitor& visitor)
{
@@ -1451,9 +1452,8 @@ void Compound::_updateInheritStereo()
const Window* window = _inherit.channel->getWindow();
const bool stereoWindow = window->getDrawableConfig().stereo;
const bool usesFBO =
window &&
window->getIAttribute(WindowSettings::IATTR_HINT_DRAWABLE) ==
fabric::FBO;
window && window->getIAttribute(WindowSettings::IATTR_HINT_DRAWABLE) ==
fabric::FBO;

if (stereoWindow && !usesFBO)
_inherit.iAttributes[IATTR_STEREO_MODE] = fabric::QUAD;
@@ -1722,5 +1722,5 @@ std::ostream& operator<<(std::ostream& os, const Compound& compound)

return os << lunchbox::exdent << "}" << std::endl << lunchbox::enableFlush;
}
}
}
} // namespace server
} // namespace eq
@@ -393,7 +393,7 @@ void LoadEqualizer::_updateNode(Node* node, const Viewport& vp,
{
default:
LBUNIMPLEMENTED;

/* fall-thru */
case MODE_VERTICAL:
leftVP.w = vp.w * .5f;
rightVP.x = leftVP.getXEnd();
@@ -1132,5 +1132,5 @@ std::ostream& operator<<(std::ostream& os, const LoadEqualizer* lb)
os << '}' << std::endl << lunchbox::enableFlush;
return os;
}
}
}
} // namespace server
} // namespace eq
@@ -66,7 +66,7 @@ class Texture
bool defined;
const GLEWContext* glewContext;
};
}
} // namespace detail

Texture::Texture(const unsigned target, const GLEWContext* const glewContext)
: _impl(new detail::Texture(target, glewContext))
@@ -109,6 +109,7 @@ uint32_t Texture::getCompressorTarget() const

default:
LBUNIMPLEMENTED;
/* fall-thru */
case GL_TEXTURE_2D:
return EQ_COMPRESSOR_USE_TEXTURE_2D;
}
@@ -214,7 +215,7 @@ static bool _isPOT(const uint32_t width, const uint32_t height)
return (width > 0 && height > 0 && (width & (width - 1)) == 0 &&
(height & (height - 1)) == 0);
}
}
} // namespace

void Texture::_grow(const int32_t width, const int32_t height)
{
@@ -464,5 +465,5 @@ std::ostream& operator<<(std::ostream& os, const Texture& texture)
<< texture.getFormat() << " type " << texture.getType()
<< std::dec << (texture.isValid() ? "" : " invalid");
}
}
}
} // namespace util
} // namespace eq
@@ -80,7 +80,7 @@ class View
std::map<uint32_t, Screenshot> screenshot;
eq::View::ScreenshotFunc screenshotFunc;
};
}
} // namespace detail

typedef fabric::View<Layout, View, Observer> Super;

@@ -193,6 +193,7 @@ bool View::handleEvent(const EventType type, const SizeEvent& event)

default:
LBUNIMPLEMENTED;
/* fall-thru */
case eq::View::TYPE_NONE:
return false;
}
@@ -212,8 +213,8 @@ void View::disableScreenshot()
void View::sendScreenshotEvent(const Viewport& viewport,
const uint32_t frameNumber, const Image& image)
{
getConfig()->sendEvent(EVENT_VIEW_SCREENSHOT) << getID() << viewport
<< frameNumber << image;
getConfig()->sendEvent(EVENT_VIEW_SCREENSHOT)
<< getID() << viewport << frameNumber << image;
}

bool View::handleEvent(EventICommand& command)
@@ -243,7 +244,7 @@ bool View::_handleScreenshot(EventICommand& command)

return true;
}
}
} // namespace eq

#include <eq/fabric/view.ipp>
template class eq::fabric::View<eq::Layout, eq::View, eq::Observer>;
@@ -48,7 +48,7 @@ bool _cmpRangesInc(const eq::ImageOp& a, const eq::ImageOp& b)
return a.image->getContext().range.start >
b.image->getContext().range.start;
}
}
} // namespace

void orderImages(eq::ImageOps& images, const eq::Matrix4f& modelviewM,
const eq::Matrix3f& modelviewITM, const eq::Matrix4f& rotation,
@@ -95,18 +95,18 @@ void orderImages(eq::ImageOps& images, const eq::Matrix4f& modelviewM,
minPos++;
if (minPos < images.size() - 1)
{
eq::ImageOps imagesTmp = images;

// copy slices that should be rendered first
memcpy(&images[nImages - minPos - 1], &imagesTmp[0],
(minPos + 1) * sizeof(eq::ImageOp));
eq::ImageOps imagesTmp;

// copy slices that should be rendered last, in reverse order
for (size_t i = 0; i < nImages - minPos - 1; ++i)
images[i] = imagesTmp[nImages - i - 1];
images.push_back(imagesTmp[nImages - i - 1]);

// copy slices that should be rendered first
std::copy(imagesTmp.begin(), imagesTmp.begin() + minPos + 1,
std::back_inserter(images));
}
}
/** @endcond */
}
} // namespace eVolve

#endif // EVOLVE_IMAGE_ORDERER_H
@@ -123,7 +123,8 @@ void VertexBufferRoot::cullDraw(VertexBufferState& state) const
#endif
break;
}
// partial range, fall through to partial visibility
// partial range, fall through to partial visibility
/* fall-thru */

case vmml::VISIBILITY_PARTIAL:
{
@@ -443,4 +444,4 @@ void VertexBufferRoot::toStream(std::ostream& os)
_data.toStream(os);
VertexBufferNode::toStream(os);
}
}
} // namespace triply

0 comments on commit b7da6bc

Please sign in to comment.
You can’t perform that action at this time.