GithubHelp home page GithubHelp logo

voxmerger's Introduction

What is VoxMerger ?

VoxMerger is a console program (Windows only) which can merge multiple MagicaVoxel scenes (.vox) into one.

VoxMerger keep only colors really used from your models and keep materials settings. If the sum of your colors in all your models is higher than 256, it will keep only the first 256 colors. So optimize your palette before merging.

WARNING: VoxMerger is deprecated !

MagicaVoxel now support the importation of a complex .vox from the IO Panel

Usage

  • You need to open a console (like cmd or Powershell in Windows)
  • Go to the emplacement of the binary
  • Launch the command : ./VoxMerger.exe --i [INPUT] --o [OUTPUT]
  • [INPUT] refer to a folder filepath (mandatory) or a list of files, each file must be separate with a comma ','
  • [OUTPUT] refer to the destination path (mandatory)

voxmerger's People

Contributors

zarbuz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

voxmerger's Issues

Instructions not clear.

The instructions only show the format for one input file, so had to guess how to pick two for the merge.

Tried:
voxmerger.exe --i house1 --i house2 --o house
voxmerger.exe --i house1.vox --i house2.vox --o house.vox

All vox files, exe and dlls are in same folder.

Error:
Unhandled Exception: System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\Users\ziplo\OneDrive\Desktop\Football Supporter Simulator\VOX\Foreground\house2'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileSystemEnumerableIterator1.CommonInit() at System.IO.FileSystemEnumerableIterator1..ctor(String path, String originalUserPath, String searchPattern, SearchOption searchOption, SearchResultHandler`1 resultHandler, Boolean checkHost)
at System.IO.Directory.GetFiles(String path)
at VoxMerger.Program.ProcessFolder(String inputFolder, String outputFile, Boolean logs, Boolean debug) in D:\Downloads\VoxMerger-master\VoxMerger-master\Program.cs:line 40
at VoxMerger.Program.Main(String[] args) in D:\Downloads\VoxMerger-master\VoxMerger-master\Program.cs:line 31

Thanks a lot for this!

First off, thanks a lot for this project! I've had to do some automation of merging vox files into a lot of different combinations, and this piece of software has really helped make that a reality. So massive kudos there!

One final question I had hoped maybe you had an answer too or know more about:

What would be the possibilities to perform a union at the end of the voxel merge to make the entire piece into a single piece instead of single items?

Encountering Sequence contains no elements

I was able to merge other Vox files but few specific files I am encountering error 'Sequence contains no elements' . Both are basic single vox model file one 40x40 other 128x128 however getting below error. Can you tell me what might be the issue.

[LOG] Started to load model: C:\opt\MagicaVoxel-0.99.6.4-win64\testmerger\input\cigar.vox
[LOG] Started to load model: C:\opt\MagicaVoxel-0.99.6.4-win64\testmerger\input\crown.vox
[INFO] Total blocks: 2337
[LOG] Started to create an optimized palette...
[LOG] Done.
[LOG] Chunk RGBA: 1036
[LOG] Chunk MATL: 16302
[LOG] Chunk SIZE: 72
[LOG] Chunk XYZI: 9396
[LOG] Chunk nGRP: 28
[LOG] Chunk nTRN: 133
[LOG] Chunk nSHP: 32
[LOG] Chunk MnTRN: 40
[LOG] Chunk MnGRP: 36
[LOG] Step [1/2]: Started to write SIZE and XYZI...
[LOG] Done.

Unhandled Exception: System.InvalidOperationException: Sequence contains no elements
at System.Linq.Enumerable.Max(IEnumerable1 source) at VoxMerger.Vox.VoxWriterCustom.WriteChunks(BinaryWriter writer) in E:\Documents\VoxMerger\Vox\VoxWriterCustom.cs:line 189 at VoxMerger.Vox.VoxWriterCustom.WriteModel(String absolutePath, List1 models) in E:\Documents\VoxMerger\Vox\VoxWriterCustom.cs:line 32
at VoxMerger.Program.ProcessFolder(String inputFolder, String outputFile, Boolean logs, Boolean debug) in E:\Documents\VoxMerger\Program.cs:line 64
at VoxMerger.Program.Main(String[] args) in E:\Documents\VoxMerger\Program.cs:line 31

Does VoxMerger apply a grouping when merging?

I've been using this for a while now (as discussed in #4) but was wondering one thing:

Does VoxMerger perform some kind of additional grouping on top of the groupings it grabs from individual files? I'd like to preserve the groupings as they are in the original files I'm merging. Is this possible?

[Request] Be able to put an offset for each axis, so as to composite smaller models side by side.

For example, I had to make a building into 3 chunks back when MV's limit was 128 voxels on an axis. I now need to merge those models side by side, not directly in place.

So if you had an offset such as:

Be able to put an offset for each axis, so as to composite smaller models side by side:

VoxMerger.exe --i ../GenericOffice5 --o ../GenericOffice5 -ox 128 -oy 0 -oz 0

or for when only one axis is needed

VoxMerger.exe --i ../GenericOffice5 --o ../GenericOffice5 -ox 128

This would make the tool MUCH more useful to people as I suspect most use cases are like that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.