Solid color support, project sampling support


The first iteration of supporting solid color for meshes has been added. This is for meshes that do not contain a texture but instead use a material with a solid color. Some examples are available here (you may need to import into blender and then export as glb.)

https://quaternius.com/

A reminder that for the glb/gltf embedded model, it still only supports a single texture and do not include other textures (such as normal map, bump map, etc.) I am working to see if multiple textures can be supported. That being said, a single texture will still perform better, since it will not create a renderer state switching to change textures.

Project sampling for embedded textures is now also supported (e.g. nearest vs trilinear). Currently, the sampling change will only take effect during runtime, until C3 adds the support for finding project sampling settings in editor mode.

If you see an older model which is using C3 image texture appear as white, this usually means that the gltf used does not include a textured material for the mesh, so you will need to add one to the model (using blender, etc.)

I have also focused on using 'regular' z axis rather than normalized z axis, because it's more intuitive for all 3d cases and also adds support for changing project fov.

So, it's recommended to set 3DObject projects to 'regular' z-axis settings.

Files

GLBExample-2-14-1.c3p 4 MB
Feb 08, 2022
3DObject-2-14-1.c3addon 51 kB
Feb 08, 2022

Get Construct 3 3DObject Plugin

Download NowName your own price

Comments

Log in with itch.io to leave a comment.

I can't figure out how to change solid colors. Do I need to export the model with different materials for the different solid colors? Can I just change the color of a material that's already a solid color?  I'm using Kenney's minigolf assets, and I'd like to be able to change the colors of the green, walls and obstacles without exporting multiple different models. Thanks!

It’s not possible to do that. You would need to different exports. The one thing you could do is change the color of the entire 3DObject (use set color or property), or apply an effect like replaceColor or Two Color Tint.

Ah okay, thanks for letting me know! I thought the change color effect  was bugged for the 3dobject but I just tried it again and it works, just doesn't display properly in the editor. Thanks again!