Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version and Workspace features not working in 3DUse #28

Open
EricBoix opened this issue Aug 30, 2017 · 10 comments
Open

Version and Workspace features not working in 3DUse #28

EricBoix opened this issue Aug 30, 2017 · 10 comments
Labels
Milestone

Comments

@EricBoix
Copy link
Contributor

Issue by johnsamuelwrites
Tuesday Feb 16, 2016 at 16:20 GMT
Originally opened as https://github.com/MEPP-team/VCity/issues/66


The tree view (left side of 3DUse) doesn't display workspace and associated versions, thereby making it difficult to test this feature. However, xlink:building types are being displayed (pointers to the original building).

Machine Details: Linux (Ubuntu)
Branch tested: Master

screenshot

@EricBoix EricBoix added this to the Someday milestone Aug 30, 2017
@EricBoix
Copy link
Contributor Author

Comment by jeremyedert
Wednesday Feb 17, 2016 at 12:28 GMT


I tried to replicate the bug under a fedora system and using the same version (master as of commit #192f1b3 ), but everything seems to work as intended (see screenshot)

capture d ecran de 2016-02-17 13 15 00

Seeing your symptoms, the problem might come for the parser not calling the corresponding temporalHandler methods during the parsing of the file, but I don't understand why it wouldn't work on your system.

@EricBoix
Copy link
Contributor Author

Comment by johnsamuelwrites
Wednesday Feb 17, 2016 at 13:20 GMT


It looks like the issue is not replicated in Xubuntu and Fedora. We were able to reproduce it on another Ubuntu machine

@EricBoix
Copy link
Contributor Author

Comment by mtola
Wednesday Feb 17, 2016 at 13:42 GMT


As I said to Jeremy just now, you can first check/compare:

  • libxml2 version ?
  • libiconv version ?
  • OS langage ?

The Qt locale is always set, so always good and always the same even if the OS is for example english or french
-> mainWindow.cpp line 192 : setlocale(LC_ALL, "C"); // MT : important for Linux

but maybe there is also a locale for libxml2 (?) for things like dates ?
-> example : day/month/year <----> month/day/year ???

...

@EricBoix
Copy link
Contributor Author

Comment by jeremyedert
Wednesday Feb 17, 2016 at 13:58 GMT


Systems where the bug occurs:

  • Ubuntu 15.10, English, with libxml2 v2.9.2
  • Ubuntu 14.04, Français, with libxml2 v2.9.1

Systems where the bug is not present:

  • Fedora 20 (december 2013), Français, with libxml2 v2.9.1
  • xUbuntu 15.10, Français, with libxml2 v2.9.2

As for the libiconv, I'm not finding it installed on my system, or at least not under this name.

@EricBoix
Copy link
Contributor Author

Comment by jeremyedert
Wednesday Feb 17, 2016 at 14:53 GMT


So after a few tests, it appears that the 'tempHandler' class (that parses elements from the temporal ADE) is indeed not instantiated.

Normally, the tempHandler::reg() method should register the 'tempHandler' class in an (static) ADE Handler factory. When we start parsing, the ADE Handler factory creates an instance of all the handlers that have been registered.

For some reason, it seems that tempHandler::reg() is not executed (or not correctly) on some systems.
Because the tempHandler is not registered in the factory, it is not instantiated at the start of the parsing, and so things like Workspaces and Versions are not parsed.

I have no idea why it doesn't work on the two Ubuntu systems.
We could manually register/instantiate the handler to solve this, but then we'd lose a functionality.

@EricBoix
Copy link
Contributor Author

Comment by mtola
Wednesday Feb 17, 2016 at 15:37 GMT


So, maybe a problem with your version of gcc (or clang ?), so for example try under Ubuntu 15.10 (with gcc 5.2.x by default...) :

  • sudo apt-get install g++-4.8
  • ...
  • and then before cmake....
  • ...
  • mkdir build48
  • CXX=g++-4.8 cmake ..
  • make

@EricBoix
Copy link
Contributor Author

Comment by johnsamuelwrites
Wednesday Feb 17, 2016 at 15:59 GMT


Using g++-4.8 led to the following errors during compilation:

....
Linking CXX executable 3DUSE
CMakeFiles/3DUSE.dir/src/gui/dialogTag.cpp.o: In function _GLOBAL__sub_I_wrapper_serializer_MyUserDataContainer': dialogTag.cpp:(.text.startup+0xdb): undefined reference toosgDB::RegisterWrapperProxy::RegisterWrapperProxy(osg::Object_, std::string const&, std::string const&, void (_)(osgDB::ObjectWrapper*))'
CMakeFiles/3DUSE.dir/src/gui/dialogTag.cpp.o:(.rodata._ZTV19MyUserDataContainer[_ZTV19MyUserDataContainer]+0xc0): undefined reference to osg::DefaultUserDataContainer::getUserObjectIndex(std::string const&, unsigned int) const' CMakeFiles/3DUSE.dir/src/gui/dialogTag.cpp.o:(.rodata._ZTV19MyUserDataContainer[_ZTV19MyUserDataContainer]+0xc8): undefined reference toosg::UserDataContainer::getUserObject(std::string const&, unsigned int)'
CMakeFiles/3DUSE.dir/src/gui/dialogTag.cpp.o:(.rodata._ZTV19MyUserDataContainer[_ZTV19MyUserDataContainer]+0xd0): undefined reference to `osg::UserDataContainer::getUserObject(std::string const&, unsigned int) const'
...
Many undefined reference errors to osg

@EricBoix
Copy link
Contributor Author

Comment by johnsamuelwrites
Thursday Feb 18, 2016 at 09:02 GMT


The code changes made by jeremyedert on his branch temporal on jeremyedert/VCity works on Ubuntu machines

@EricBoix
Copy link
Contributor Author

Comment by jeremyedert
Thursday Feb 18, 2016 at 10:32 GMT


Pull request #71 contains the workaround.
New ADE handlers will need to be added manually in the future, but at least it works.

@EricBoix
Copy link
Contributor Author

Comment by mtola
Thursday Feb 18, 2016 at 12:38 GMT


Without the fix, on my Ubuntu 15.10, Français, with libxml2 v2.9.2, it works perfectly.

For me it's the language because Ubuntu 15.10, English, with libxml2 v2.9.2 don't work...

So are you really sure for this config : Ubuntu 14.04, Français, with libxml2 v2.9.1 ???
Is it really a french one ?
(may be it's an english install and then french was add after ???)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant