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

Usage information? #4

Open
sudofox opened this issue Oct 19, 2021 · 4 comments
Open

Usage information? #4

sudofox opened this issue Oct 19, 2021 · 4 comments

Comments

@sudofox
Copy link

sudofox commented Oct 19, 2021

I'm trying to design a base and am working to understand how 3d models work in order to do so.

Your example shows Waluigi Pinball (my favorite MKDS track) which immediately caught my attention. However, from a bit of research it seems like things such as textures and colors have to be loaded separately from .obj files, whereas the GUI portion of Obj2MC doesn't seem to have a way to load them. How would I go about doing this? (The theme is "solar system" so I'll need to be able to load the colors/textures for each planet.)

Furthermore -- I am more comfortable using CLI arguments than using GUIs, and I see in the commit history that you added a GUI, however I don't see any details about how to specify CLI arguments?

Perhaps you could supply the sample files used to generate the examples in README.md.

Thanks for the help -- you're making my day a lot easier.

@sudofox
Copy link
Author

sudofox commented Oct 20, 2021

Update: I worked out that it searches for MTL and such, however it does error out if the filenames contain spaces.

@Garhoogin
Copy link
Owner

Hello, sorry for the late response, and sorry that I haven't really touched this project much at all lately. I moved the project from a command line based program to a GUI based one, though the older release has the older interface. Though that older interface didn't provide more options than the GUI does, I really didn't like it very much.
The color information it gets from MTL files specified in the OBJ file's mtllib line. From there it uses a material definition file to map the colors of the texture to a color you specify. It's not the most elegant thing in the world, it's just what I was able to come up with at that moment.
I looked into the issue you mentioned about MTL files with spaces in the file name causing issues, and I do see where in the code this would be caused, in ObjReader.java line 114. In theory a simple fix to get spaces in the file names working.
Glad to know you found the program useful though :)

@sudofox
Copy link
Author

sudofox commented Oct 20, 2021

Yeah, the program is great!! I'm really looking forward to making some amazing things with it in survival, so expect to see more of me soon as I put it through its paces.

I think the next steps for me are to write a script to process the default texture pack to generate the color/material info to feed into the program. We'll see... maybe expect a pull from me sometime if I have more free time.

@inxomnyaa
Copy link

inxomnyaa commented Jan 10, 2022

Coincidentally, hueblocks has a python script for that https://github.com/1280px/hueblocks/tree/main/data/!!%20blox2rgb

it outputs a Javascript array for all textures, but that can easily be converted into the material definition format. I already ran the program for the bedrock game versions 1.14 - 1.18 here 1280px/hueblocks#2 (comment) and the project itself has 1.17 or 1.18 blocks https://github.com/1280px/hueblocks/blob/main/data/blocksets/blocks.js

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

3 participants