SolveSpace Logo SOLVESPACE -- parametric 2d/3d CAD
Examples
Tutorials
Features
Download
Reference
Technology
Library
Forum
Contact
USER FORUM

(you are viewing a thread; or go back to list of threads)

Any Entity remap list available? (by Vicky)
Entity prop "Entity.h.v" gets changed when inserting existing part into the assembly, do we have any method/workaround to find what the news "Entity.h.v" is? any remap list?
Thu Aug 25 2022, 03:50:27
(no subject) (by Paul)
A linked group remaps entities using the remap function. See Group::Generate() and Group::CopyEntity()

However I'm still not clear on the file reading. I think entites are created as numeric on reading the file and then copied as N_ROT_TRANS so the linked entities can be rotated and translated.

Due to the remapping the entities in linked groups will have different IDs than in the source file, and possibly different in each instance (though I think they will be accidentally the same?)

I'm not certain how easy it is to return the original ID, but there is likely a function for that too. Not sure why you'd want it.

What are you up to?
Thu Aug 25 2022, 13:44:21
(no subject) (by Vicky)
Since I am porting this library and writing a wrapper for use in unity c#, i need this functionality.

Let me explain. I have few parts pre-made in solvespace.

I have a script that assemble all these files by applying rotation and translation to each part while linking.

Till this step it's successful and i can see assembly drawn in unity.

Now i need to create dimensions in front end(unity) and for that need "Point entity" information to draw dimension lines between them.

I keep track of Entity.h.v while making part, but that changes in assembly, so I need some way to track point location. I basically search through solvespace entity list and get X and Y location.

I hope you get why I need this. You can recommend or suggest an alternate.
Thu Aug 25 2022, 14:27:07
(no subject) (by Vicky)
@paul I guess this is what remaps the entity?
"en.h = Remap(ep->h, remap)" inside Group::CopyEntity()

You mentioned there might already be a function to get original entity.h.v, can you help me find out that function?
Sat Aug 27 2022, 09:06:34
(no subject) (by Paul)
@Vicky once again I'm not sure where you're going with all this. Remap was never meant to go in reverse like that. It might, but I don't know.
Sat Aug 27 2022, 11:22:26
(no subject) (by Vicky)
In simple language, writing wrapper to use solvespace as modelling kernel in c#.
Mon Aug 29 2022, 07:52:01
Post a reply to this comment:
Your Name:
Your Email:
Subject:
(no HTML tags; use plain text, and hit Enter for a line break)
Attached file (if you want, 5 MB max):
© 2008-2022 SolveSpace contributors. Most recent update June 2 2022.