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

Add support for new MagicaVoxel format #6

Open
virtualritz opened this issue May 17, 2019 · 1 comment
Open

Add support for new MagicaVoxel format #6

virtualritz opened this issue May 17, 2019 · 1 comment

Comments

@virtualritz
Copy link

virtualritz commented May 17, 2019

See here for format extensions.

I tried the simple visualization example with the castle.vox model that ships with MagicaVoxel. I get this:

2019-05-17 15:00:59 foo.home pyvox.parser[26148] DEBUG Found chunk id b'MAIN' / len 0 / children 39931
2019-05-17 15:00:59 foo.home pyvox.parser[26148] DEBUG Found chunk id b'SIZE' / len 12 / children 0
2019-05-17 15:00:59 foo.home pyvox.parser[26148] DEBUG Found chunk id b'XYZI' / len 10516 / children 0
2019-05-17 15:00:59 foo.home pyvox.parser[26148] DEBUG xyzi block with 2628 voxels (len 10516)
2019-05-17 15:00:59 foo.home pyvox.parser[26148] DEBUG Found chunk id b'nTRN' / len 28 / children 0
Traceback (most recent call last):
  File "./test.py", line 10, in <module>
    m = VoxParser(sys.argv[1]).parse()
  File "/usr/local/lib/python3.7/site-packages/pyvox/parser.py", line 93, in parse
    main = self._parseChunk()
  File "/usr/local/lib/python3.7/site-packages/pyvox/parser.py", line 81, in _parseChunk
    chunks.append(self._parseChunk())
  File "/usr/local/lib/python3.7/site-packages/pyvox/parser.py", line 83, in _parseChunk
    return Chunk(_id, content, chunks)
  File "/usr/local/lib/python3.7/site-packages/pyvox/parser.py", line 55, in __init__
    raise ParsingException('Unknown chunk type: %s'%self.id)
pyvox.parser.ParsingException: Unknown chunk type: b'nTRN'
@midstreeeam
Copy link

Hi, I also met this problem, so I did some modification on this module, basically for myself to use, but it might help you.
Maybe you can check https://github.com/midstreeeam/PyVox

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

No branches or pull requests

2 participants