1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

added addTextOpenGl function

This commit is contained in:
Vladislav Vinogradov
2011-11-28 11:50:46 +00:00
parent 2a4fb155e1
commit 9817252b23
5 changed files with 370 additions and 58 deletions
+39
View File
@@ -597,6 +597,35 @@ void cv::pointCloudShow(const string& winname, const gpu::GlCamera& camera, Inpu
#endif
}
// OpenGL text
void cv::addTextOpenGl(const string& winname, const string& text, Point org, Scalar color, const string& fontName, int fontHeight, int fontWeight, int fontStyle)
{
cvAddTextOpenGl(winname.c_str(), text.c_str(), org, color, fontName.c_str(), fontHeight, fontWeight, fontStyle);
}
void cv::clearTextOpenGl(const string& winname)
{
cvClearTextOpenGl(winname.c_str());
}
#if (!defined WIN32 && !defined _WIN32) || defined HAVE_QT
CV_IMPL void cvAddTextOpenGl(const char*, const char*, CvPoint, CvScalar, const char*, int, int, int)
{
CV_Error(CV_OpenGlNotSupported, "This function works only under WIN32");
}
CV_IMPL void cvClearTextOpenGl(const char*)
{
CV_Error(CV_OpenGlNotSupported, "This function works only under WIN32");
}
#endif // (!defined WIN32 && !defined _WIN32) || defined HAVE_QT
// Without OpenGL
#ifndef HAVE_OPENGL
#ifndef HAVE_QT
@@ -616,6 +645,16 @@ CV_IMPL void cvUpdateWindow(const char*)
CV_Error(CV_OpenGlNotSupported, "The library is compiled without OpenGL support");
}
CV_IMPL void cvAddTextOpenGl(const char*, const char*, CvPoint, CvScalar, const char*, int, int, int)
{
CV_Error(CV_OpenGlNotSupported, "The library is compiled without OpenGL support");
}
CV_IMPL void cvClearTextOpenGl(const char*)
{
CV_Error(CV_OpenGlNotSupported, "The library is compiled without OpenGL support");
}
void icvSetOpenGlCleanCallback(const char*, CvOpenGlCleanCallback, void*)
{
CV_Error(CV_OpenGlNotSupported, "The library is compiled without OpenGL support");