Texture mapping

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
Chris_G
Veteran
Posts: 2572
Joined: Tue Dec 31, 2013 4:10 pm
Location: France
Contact:

Re: Texture mapping

Post by Chris_G »

It maps the texture on the inside the environment cube (not sure it is a cube actually), so that all objects will reflect it.
User avatar
kaktus
Veteran
Posts: 1149
Joined: Sun Aug 11, 2019 11:59 am
Location: opolskie
Contact:

Re: Texture mapping

Post by kaktus »

In other words
meaning the area in the bounding box :?:
Twórca polskiej wersji Wiki dla FreeCAD, współwórca polskiej wersji GUI.
"Cierpliwym być musisz, by wiedzę zgłębiać tajemną, gdyż ciemna strona mocy niszczącą i silną jest".
drmacro
Veteran
Posts: 8806
Joined: Sun Mar 02, 2014 4:35 pm

Re: Texture mapping

Post by drmacro »

dprojects wrote: Sun Apr 03, 2022 1:34 pm ...The FreeCAD Texture Mapping don't work with faces. It only apply texture for all available objects. But I found it very useful for quick preview.
I am not sure if at FreeCAD there is way to apply texture per face, you know different texture on each face. For sure there is possibility to rotate the face but I didn't look at this yet so deeply.

...
Doesn't matter, if I select the View>Texture mapping and select an image. The solids in the 3D view just turn black.
Attachments
Snip macro screenshot-298069.png
Snip macro screenshot-298069.png (122.94 KiB) Viewed 1507 times
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
User avatar
dprojects
Posts: 720
Joined: Mon Mar 06, 2017 6:02 pm
Location: Poland
Contact:

Re: Texture mapping

Post by dprojects »

drmacro wrote: Sun Apr 03, 2022 3:00 pm Doesn't matter, if I select the View>Texture mapping and select an image. The solids in the 3D view just turn black.
Should not be like this if the texture is valid. However, if you have applied color the texture will not be set, maybe this is why.

EDIT:

Check object property box for color, shape and everything related to color. If this is fine maybe the theme style overwrite default object color. Maybe this is black by default.

Thanks
Darek
github.com/dprojects

workbench for woodworking is available at: github.com/dprojects/Woodworking
User avatar
dprojects
Posts: 720
Joined: Mon Mar 06, 2017 6:02 pm
Location: Poland
Contact:

Re: Texture mapping

Post by dprojects »

kaktus wrote: Sun Apr 03, 2022 2:36 pm I think that many users would also be satisfied if there was a scaling option. :idea:
If I would know how to change texture size with the coin library I would add it. But I don't see any option at coin.SoTexture2, anyone?

Thanks
Darek
github.com/dprojects

workbench for woodworking is available at: github.com/dprojects/Woodworking
drmacro
Veteran
Posts: 8806
Joined: Sun Mar 02, 2014 4:35 pm

Re: Texture mapping

Post by drmacro »

dprojects wrote: Sun Apr 03, 2022 3:46 pm
drmacro wrote: Sun Apr 03, 2022 3:00 pm Doesn't matter, if I select the View>Texture mapping and select an image. The solids in the 3D view just turn black.
Should not be like this if the texture is valid. However, if you have applied color the texture will not be set, maybe this is why.

EDIT:

Check object property box for color, shape and everything related to color. If this is fine maybe the theme style overwrite default object color. Maybe this is black by default.
What is a valid texture?

The cube is default from Part workbench Cube primitive. No colors.
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
User avatar
dprojects
Posts: 720
Joined: Mon Mar 06, 2017 6:02 pm
Location: Poland
Contact:

Re: Texture mapping

Post by dprojects »

drmacro wrote: Sun Apr 03, 2022 3:53 pm What is a valid texture?
Valid image format, without unexpected characters for the format. Try other texture. Or try to turn off the FreeCAD layout color schema. Maybe this overwrite the object at the FreeCAD system level. The cube should not be black by default. So something is wrong at your FreeCAD installation or configuration.

Thanks
Darek
github.com/dprojects

workbench for woodworking is available at: github.com/dprojects/Woodworking
User avatar
Chris_G
Veteran
Posts: 2572
Joined: Tue Dec 31, 2013 4:10 pm
Location: France
Contact:

Re: Texture mapping

Post by Chris_G »

dprojects wrote: Sun Apr 03, 2022 3:50 pm If I would know how to change texture size with the coin library I would add it. But I don't see any option at coin.SoTexture2, anyone?
You must insert a SoTexture2Transform node before your texture node.
User avatar
dprojects
Posts: 720
Joined: Mon Mar 06, 2017 6:02 pm
Location: Poland
Contact:

Re: Texture mapping

Post by dprojects »

Chris_G wrote: Sun Apr 03, 2022 4:06 pm You must insert a SoTexture2Transform node before your texture node.
it has rotation but has also repeat if texture not cover all the cube size? I came across something like REPEAT but I have no idea how to use it yet, this would be useful to apply not full texture but only brick or marble pattern that would be populated on the whole wall for example.

Thanks
Darek
github.com/dprojects

workbench for woodworking is available at: github.com/dprojects/Woodworking
User avatar
Chris_G
Veteran
Posts: 2572
Joined: Tue Dec 31, 2013 4:10 pm
Location: France
Contact:

Re: Texture mapping

Post by Chris_G »

I don't know much about textures, but this may be an interesting reading :
http://www-evasion.imag.fr/Membres/Fran ... /ch07.html
Post Reply