Arch Texture Addon: Help Requests
Forum rules
and Helpful information
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!
Also, be nice to others! Read the FreeCAD code of conduct!
Arch Texture Addon: Help Requests
If you have questions or problems with the Arch Texture Workbench please do not post to the Announcements Topic anymore but instead Reply to this Topic. So everything is in the appropriate Forum.
New features are still announced in this topic: https://forum.freecadweb.org/viewtopic. ... a666fc1c40
New features are still announced in this topic: https://forum.freecadweb.org/viewtopic. ... a666fc1c40
Re: Arch Texture Addon: Help Requests
Hi Furti,
many thanks for your addon.
I've got a problem resolving textures but I can't realy pick the Freecad release when it first started. Anyway I am working with your latest add-on release and this freecad environnment:
context
openging a project with some texture configured
erro in the Freecad report view and project file is open but textures aren't resolved
error msg
error comment
It looks like the shadedNode object isn't resolved in the texture_manager.py file (line 104) and
and a "None" object is then used as parameter without subsequent test on parameter "nullity" before asling for it's supposed attributes
faceset_utils.py (line 416)
error details
when I then hit the space button on the textureConfig files all seams to work ok.
N.B.:
and here the trace when hitting the space key
Are we always supposed to find "shadedNode" object ?
Thanks for your help.
many thanks for your addon.
I've got a problem resolving textures but I can't realy pick the Freecad release when it first started. Anyway I am working with your latest add-on release and this freecad environnment:
OS: macOS 10.14
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.17681 (Git)
Build type: Release
Branch: master
Hash: e94af7ff5e873f263cac51d7d47df68eca183250
Python version: 3.7.3
Qt version: 5.9.7
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: French/France (fr_FR)
context
openging a project with some texture configured
erro in the Freecad report view and project file is open but textures aren't resolved
error msg
Traceback (most recent call last):
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 272, in onChanged
self.textureConfig.execute(self.Object)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 225, in execute
self.textureManager.textureObjects()
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_manager.py", line 106, in textureObjects
brep = faceset_utils.findBrepFaceset(shadedNode)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/arch_texture_utils/faceset_utils.py", line 433, in findBrepFaceset
children = node.getChildren()
<class 'AttributeError'>: 'NoneType' object has no attribute 'getChildren'
error comment
It looks like the shadedNode object isn't resolved in the texture_manager.py file (line 104) and
Code: Select all
shadedNode = faceset_utils.findShadedNode(switch)
Code: Select all
brep = faceset_utils.findBrepFaceset(shadedNode)
Code: Select all
def findShadedNode(node):
[color=#FF0000]children = node.getChildren()[/color]
if children is None or children.getLength() == 0:
return None
for child in children:
if child.getTypeId().getName() == 'SoBrepFaceSet':
return node
shadedNode = findShadedNode(child)
if shadedNode is not None:
return shadedNode
error details
when I then hit the space button on the textureConfig files all seams to work ok.
N.B.:
- I've got 2 texture config "textureTuileConcassees" and "textureBardageVertical". The error is hitten on the resolution of the first texture.
- I've added a print comment before the error line in the
faceset_utils.py file e.g. "----- node :...."
Removing Textures
Removing Textures
Texturing objects
Texturing textureTuileConcassees
----- node : None
Traceback (most recent call last):
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 272, in onChanged
self.textureConfig.execute(self.Object)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 225, in execute
self.textureManager.textureObjects()
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_manager.py", line 106, in textureObjects
brep = faceset_utils.findBrepFaceset(shadedNode)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/arch_texture_utils/faceset_utils.py", line 433, in findBrepFaceset
children = node.getChildren()
<class 'AttributeError'>: 'NoneType' object has no attribute 'getChildren'
and here the trace when hitting the space key
Texturing objects
Texturing textureTuileConcassees
----- node : <pivy.coin.SoSeparator; proxy of <Swig Object of type 'SoSeparator *' at 0x15b118960> >
Texturing textureBardageVertical
----- node : <pivy.coin.SoSeparator; proxy of <Swig Object of type 'SoSeparator *' at 0x15b118de0> >
Are we always supposed to find "shadedNode" object ?
Thanks for your help.
Re: Arch Texture Addon: Help Requests
Thanks for pointing this out. I think the problem only occurs, when you open a document where a TextureConfig is visible. Then it could happen, that the TextureConfig is executed before all view objects are set up correctly.
I added a fix for this. Now when no shaded node is found the object is not textured and a message, containing the object Label, is logged to the Report View. So one can easily see when a object is skipped because of a missing ShadedNode.
I don't know if there are Objects that have no ShadedNode. But it is possible that Nodes with other types of FaceSets will not be texturable with the current implementation.
I added a fix for this. Now when no shaded node is found the object is not textured and a message, containing the object Label, is logged to the Report View. So one can easily see when a object is skipped because of a missing ShadedNode.
I don't know if there are Objects that have no ShadedNode. But it is possible that Nodes with other types of FaceSets will not be texturable with the current implementation.
Re: Arch Texture Addon: Help Requests
Hi Furti,
thanks a lot. I downloaded your last commit and it's fixed.
Cheers
thanks a lot. I downloaded your last commit and it's fixed.
Cheers
Re: Arch Texture Addon: Help Requests
Hi furti,
sorry to botter again but I am facing with a problem on my freecad project files since the last FreeCAD comit (Version: 0.19.17798 (Git)) cf.https://forum.freecadweb.org/viewtopic. ... 11#p328211
Since this commit (but it was OK in earlier FreeCAD version) I am not able to resolve my ArcTextures anymore.
error
when trying to resolve te TextureConfig files I've got the following error
comment
I don't know why but ArchMaterial object in the ArchTexture script is resolved as a dictionnary
and no more as a real python object? Hence material.Name is not resolved but material['Name'] would.
The thing is that when querying the material objet in freecad python console, the object is well resolved as a real pythonObject.
Sory againt but I hope you've got an Idea on this problem which isn't probably specific to your workbench?
Thanks anyway
sorry to botter again but I am facing with a problem on my freecad project files since the last FreeCAD comit (Version: 0.19.17798 (Git)) cf.https://forum.freecadweb.org/viewtopic. ... 11#p328211
Since this commit (but it was OK in earlier FreeCAD version) I am not able to resolve my ArcTextures anymore.
error
when trying to resolve te TextureConfig files I've got the following error
Traceback (most recent call last):
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 272, in onChanged
self.textureConfig.execute(self.Object)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_config.py", line 225, in execute
self.textureManager.textureObjects()
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_manager.py", line 96, in textureObjects
texture, bumpMap, textureConfig = self.getTextureForMaterial(o.Material)
File "/Users/bblockmans/Library/Preferences/FreeCAD/Mod/ArchTextures/texture_manager.py", line 205, in getTextureForMaterial
materialName = material.Name
<class 'AttributeError'>: 'dict' object has no attribute 'Name'
'dict' object has no attribute 'Name'
comment
I don't know why but ArchMaterial object in the ArchTexture script is resolved as a dictionnary
Code: Select all
material = {'Color': '(0.762905317769131, 0.2041962310215915, 0.03569085221637293)', 'Description': 'tuiles en terre cuite concassées', 'DiffuseColor': '(0.762905317769131, 0.2041962310215915, 0.03569085221637293)', 'Name': 'tuilesConcasées', 'ProductURL': '', 'StandardCode': '', 'Transparency': '0', 'ViewColor': '(0.762905317769131, 0.2041962310215915, 0.03569085221637293)'}
The thing is that when querying the material objet in freecad python console, the object is well resolved as a real pythonObject.
Sory againt but I hope you've got an Idea on this problem which isn't probably specific to your workbench?
Thanks anyway
Re: Arch Texture Addon: Help Requests
No need to excuse. Its important to report bugs when you find them. I appreciaze that a lot.
I had a look and found the problem. It is not about the material property of the objet to texture, it is the material itself that causes a problem. The mazerial has a "Material" property and since some commits it seems to have a "Shape" property too. So it is picked as a candidate for texturing as it looks like a texturable object.
I will try to provide a fix tomorrow.
I had a look and found the problem. It is not about the material property of the objet to texture, it is the material itself that causes a problem. The mazerial has a "Material" property and since some commits it seems to have a "Shape" property too. So it is picked as a candidate for texturing as it looks like a texturable object.
I will try to provide a fix tomorrow.
Re: Arch Texture Addon: Help Requests
I pushed a fix for this. Now only objects with non null shapes will be candidates for texturing.
Re: Arch Texture Addon: Help Requests
Hi furti,
You did a very nice your work with your FreeCAD ArchTextures workbench.
However I am really struggling to understand how I can use it. I have tried to follow the instructions of the workbench readme file (https://github.com/furti/FreeCAD-ArchTextures), and have created a material assigned material to my objects. But I am not able to figure out how performing them:
Do I need to use FC 0.19? I use the current stable version 0.18.4.
Thanks for your help!
drolli
You did a very nice your work with your FreeCAD ArchTextures workbench.
However I am really struggling to understand how I can use it. I have tried to follow the instructions of the workbench readme file (https://github.com/furti/FreeCAD-ArchTextures), and have created a material assigned material to my objects. But I am not able to figure out how performing them:
- Select the object in the TreeView
- Right click in the Data Tab and click "Show all"
- Right click again and click "Add property"
Do I need to use FC 0.19? I use the current stable version 0.18.4.
Thanks for your help!
drolli
Code: Select all
OS: Windows 10
Word size of OS: 64-bit, Word size of FreeCAD: 64-bit
Version: 0.18.4 (GitTag), Build type: Release, Branch: releases/FreeCAD-0-18
Python version: 3.6.6, Qt version: 5.6.2, Coin version: 4.0.0a, OCC version: 7.3.0
Re: Arch Texture Addon: Help Requests
Did you read the information in README.md?
To use textures you need objects that have the "Material" property. In 0.18 only architectural objects, like Arch Wall, have such property.README.md wrote: Texture mapping
Currently Texture Mapping only works with objects that have a Material assigned. All architectural objects have such a property. To create a material, go to the Arch workbench and create a material there. See https://www.freecadweb.org/wiki/Arch_SetMaterial for further details.
...
From FreeCAD 0.19 onwards, it is possible to also texture objects created with other workbenches than the Arch workbench.
Version 0.19 introduced many new underlying features, one of which is that now you can add properties in real time to any object in the tree view. So, in 0.19 you can add the Material property to any object that you have, whether it was created with Arch Workbench or not.
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.