Comments (5)
Can you please post a file showing the wrong shape?
from freecad.
Hmm... I'm trying to find the file where I saw the problem, but can't reproduce it.
I've used many old tutorial files, which probably were created with some old or custom build versions.
Will keep an eye on that and report if I'll see it again.
Anyway, the "Shape" property is not listed for Link object in the console, while it is accessible.
And something I want to confirm:
Does the link attachment offsets are applied to the Shape information as well?
I mean, if an object has offset of 100mm on X axis, will the Center of BoundBox have that offset as well?
from freecad.
Here... Found it...
test.zip
Open the test1.FCStd file, it have a link to goTUBE 336mm.FCStd
The goTUBE 336mm.FCStd file was created with imported STEP.
Send "goTUBE 336mm.FCStd" entry from the tree to Python console
>>> obj.Shape.BoundBox
BoundBox (-15.8585, -1e+100, -15.975, 15.8585, 1e+100, 15.975)
Send "goTUBE 336mm.FCStd" entry from the tree to Python console
>>> obj.Shape.BoundBox
BoundBox (-15.8585, 0, -15.975, 15.8585, 336, 15.975)
from freecad.
What did your second obj.Shape.Boundbox
refer to? I think you made a typo. Are you referring to the tube model? The Link to model gives the compound of all its children shape, including those datum lines.
Anyway, the "Shape" property is not listed for Link object in the console, while it is accessible.
It is not listed because it is not a real FreeCAD property. It is actually implemented as a Python attribute. It is dynamically calculated by calling Part.getShape()
. In other words, getattr(link, 'Shape')
is equivalent to Part.getShape(link)
. And yes, it will adjust the returned shape's placement according to the link placement.
The same things goes for App.Part
, i.e. getattr(part, 'Shape')
is equivalent to Part.getShape(part)
, which returns a compound of its children in part's placement.
from freecad.
What did your second
obj.Shape.Boundbox
refer to? I think you made a typo. Are you referring to the tube model? The Link to model gives the compound of all its children shape, including those datum lines.
Sorry, copy&paste didn't work when typing...
I meant goTUBE_336mm link and "4103-0032-0336" body of the object.
So, based on your answer, Shape is not relevant for Assembly4 since its using FC's elements that define an object such as line... That might be a problem on the long run if Assembly4 will become popular...
Anyway, the "Shape" property is not listed for Link object in the console, while it is accessible.
It is not listed because it is not a real FreeCAD property. It is actually implemented as a Python attribute. It is dynamically calculated by calling
Part.getShape()
. In other words,getattr(link, 'Shape')
is equivalent toPart.getShape(link)
. And yes, it will adjust the returned shape's placement according to the link placement.
I'm not familiar with the code that much, but I as saw, Visibility is also an attribute that run show/hide functions based on the call, but it's still shown in the python console.
from freecad.
Related Issues (20)
- [Problem] GUI: right side and bottom of dialog text is cut off HOT 2
- [Problem] toolbar items become stuck if you accidentally drop them in the top row next to "file" "edit" etc. HOT 3
- [Problem] PartDesign Mirrored (It is impossible to leave only the mirrored part.)
- [Problem] How to get realthunder FreeCAD working on ChromeOS Linux? HOT 5
- [Problem] [Ergonomics] PD: Ordering of sketches in "Map Sketch to Face" dialog drop-down menu.
- Menubar is missing
- [Problem] Sketcher symmetry ignores external geometry.
- [Problem] Crash when deleting detached defining geometry in Sketcher.
- [Problem] Lost Camera
- [Problem] No access any more to subshapebinder / external geometry after changes made to the master sketch it points to.
- [Problem] Item Background color
- [Problem] Crash when making a Compound out of a Mesh
- [Problem] recompute crash when changing a length property. HOT 1
- [Problem] Point constraints not being highlighted in Sketcher HOT 1
- [Problem] Transformation Offset moves original feature as well HOT 3
- [Problem] PartDesign Pad UpToFace broken if face to be padded exceeds the target HOT 2
- [Problem] crash when updating configuration table
- [Problem] Number editing doesn't work after project open.
- [Problem] Can the configuration table support column direction parameters?
- [Problem] PartDesign Thickness, I failed to select 3 faces.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from freecad.