![]() |
Здравствуйте, гость ( Вход | Регистрация )
![]() |
kemiisto |
![]() ![]()
Сообщение
#1
|
![]() Студент ![]() Группа: Участник Сообщений: 27 Регистрация: 5.9.2009 Из: Осло, Норвегия Пользователь №: 1054 Спасибо сказали: 2 раз(а) Репутация: ![]() ![]() ![]() |
Здравствуйте!
Если у кого-нибудь найдётся минутка-другая, посмотрите проектик. Исходники Link. Я не стал убирать *.dll и *.a от QGLViewer'а и инклюды от QGLViewer'а и Eigen'а. Так чтоб под Windows собиралось "из коробки"... Я первый раз пишу на ++ и проект только-только начинается. Так что там много методов-пустышек и "говнокода". ![]() Собственно, беда такая. Есть у нас класс (молекула)
В Render::Viewer попытка использовать экземпляр этого класса
Попытка не совсем успешная. Когда отрабатывает конструктор Chemistry::Molecule, все 3 списка инициализируются. ![]() При попытке добавить атом в Render::Viewer::mousePressEvent в самом начале ставим точку останова: ![]() Вот. Куда то пропал incidenceMatrix_. Куда? А самое интересное. Если в объявлении поменять местами скажем так:
то на точке останова не будет уже chemistryBonds_. То есть получается: кто первым объявлен (первым инициализируется в конструкторе), тот куда-то пропадает. Немного побегал дебагом. Список портится внутри void Render::Viewer::updateMolecule(). До вызова updateGL() всё отлично, после <internal error>. А это метод (точнее слот) QGLViewer'а. Мыслей больше нет. ![]() |
|
|
![]() |
Kagami |
![]()
Сообщение
#2
|
Старейший участник ![]() ![]() ![]() ![]() Группа: Участник Сообщений: 601 Регистрация: 2.2.2009 Пользователь №: 523 Спасибо сказали: 101 раз(а) Репутация: ![]() ![]() ![]() |
У меня не собирается
Раскрывающийся текст Цитата Sources/Render/RenderViewer.cpp: In member function ‘virtual void Render::Viewer::draw()’: Sources/Render/RenderViewer.cpp:144: error: ‘((Render::Viewer*)this)->QWidget::font’ does not have class type Sources/Render/RenderViewer.cpp:145: error: no matching function for call to ‘Render::Viewer::renderText(int, int, const char [11], <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) Sources/Render/RenderViewer.cpp:146: error: ‘((Render::Viewer*)this)->QWidget::font’ does not have class type Sources/Render/RenderViewer.cpp:150: error: no matching function for call to ‘Render::Viewer::renderText(int, int, const char [11], <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) Sources/Render/RenderViewer.cpp:158: error: no matching function for call to ‘Render::Viewer::renderText(int, int, const char [10], <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) Sources/Render/RenderViewer.cpp:161: error: no matching function for call to ‘Render::Viewer::renderText(int, int, QString, <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) Sources/Render/RenderViewer.cpp:166: error: no matching function for call to ‘Render::Viewer::renderText(int, int, QString, <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) Sources/Render/RenderViewer.cpp:168: error: no matching function for call to ‘Render::Viewer::renderText(int, int, QString, <unresolved overloaded function type>)’ /usr/include/qt4/QtOpenGL/qgl.h:441: note: candidates are: void QGLWidget::renderText(int, int, const QString&, const QFont&, int) /usr/include/qt4/QtOpenGL/qgl.h:443: note: void QGLWidget::renderText(double, double, double, const QString&, const QFont&, int) make[1]: *** [Build/Objects/release/RenderViewer.o] Ошибка 1 P.S. Debian GNU/Linux Squeeze P.P.S. Из-за вот этого куска:
Судя по-всему, поддержка линукса не предусмотрена ![]() Сообщение отредактировал Kagami - 6.9.2009, 22:12 |
|
|
![]() ![]() ![]() |
![]() |
|
Текстовая версия | Сейчас: 11.8.2025, 12:43 |