pierrep / lpmt

Rewrite of the Little Projection Mapping Tool (http://projection-mapping.org/tools/lpmt/)
GNU General Public License v3.0
55 stars 4 forks source link

Gui error #4

Closed wangwenfeng0 closed 4 years ago

wangwenfeng0 commented 4 years ago

When I compile the source code, it will produce an access rights conflict in the xtree file, the function name is "template _Nodeptr _Lbound(const _Other& _Keyval) const { // find leftmost node not less than _Keyval _Nodeptr _Wherenode = this->_Get_data()._Myhead; // end() if search fails _Nodeptr _Pnode = _Wherenode->_Parent; } " the error information is : _Wherenode is nullpter image image

When I remove the gui source codes, it will be no error. How could I fix this problem, thank you very much.

pierrep commented 4 years ago

What platform and compiler are you seeing this on? You may have set up your build environment incorrectly

On Sat., 21 Mar. 2020, 11:33 pm 王文锋, notifications@github.com wrote:

When I compile the source code, it will produce an access rights conflict in the xtree file, the function name is "template _Nodeptr _Lbound(const _Other& _Keyval) const { // find leftmost node not less than _Keyval _Nodeptr _Wherenode = this->_Get_data()._Myhead; // end() if search fails _Nodeptr _Pnode = _Wherenode->_Parent; } " the error information is : _Wherenode is nullpter [image: image] https://user-images.githubusercontent.com/16935291/77226329-75a01e80-6bb2-11ea-8285-6cbf85c66663.png [image: image] https://user-images.githubusercontent.com/16935291/77226340-8a7cb200-6bb2-11ea-8188-17442f421c60.png

When I remove the gui source codes, it will be no error. How could I fix this problem, thank you very much.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/pierrep/lpmt/issues/4, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAC7XYATWE7BOD6QPFL4T53RISXYZANCNFSM4LQ4YXBA .

wangwenfeng0 commented 4 years ago

I use the Windows 10 system with openframeworks 0.11.0, and the compiler is VS2017. I have tracked the error in the code, when in the ofxSimpleGuiConfig.cpp to run the ttf.load("data/type/Roboto-Regular.ttf", 9); it will produce the error. image image image

I find the fonts_table size is zero, thank you for your reply, I will try to fix it.

pierrep commented 4 years ago

Interesting, thanks for debugging. I'll compile it in Windows (I'm using a similar setup, vs2017, OF 0.11.0, Windows 10) and see if I can reproduce it.

pierrep commented 4 years ago

You can work around it for the moment by changing the code to this:

    /* set up font */
    bUseFont = false;
//    ttf.load("data/type/Roboto-Regular.ttf", 9);
pierrep commented 4 years ago

Can you get the latest code? It should be fixed.

wangwenfeng0 commented 4 years ago

OK, I will test it, It should be fixed with your work, thank you.