I need to figure out a way to capture all of the objects' locations and save to a file.
I am working on a machine simulator for bending sheet metal parts. I am thinking that I want the user to be able to set the machine settings for each bend on the sheet metal part and then click a button to save the settings. The sheet metal part can have many bends, so I need to be able to save many machine settings.
For example:
Image a box without a lid. It will have 5 sides...a left, right, back, front and bottom. To make a sheet metal box like that it will start off flat and look similar to a cross. If you fold up each of the 4 legs of the cross, you will end up with a 5 sided box.
So I have a "machine" programmed in Blitz that allows the user to import a flat sheet metal part from a CAD system. The user can move the flat part on the screen and also move parts of the machine around until the part and machine "fit" like the user wants. Once the machine setup is correct, I want the user to be able to click on a button that will "save" all of these positions...the part positions and machine positions. For each bend on the part, I will need to be able to save the part and machine positions.
Ultimately, I want to be able to recall these part and machine positions and play them back on the screen and maybe even change the order of the playback.
I feel confident that I can write a file to save this information but I need help with how to "Capture all of the positions so that I can write them to the file.
So...Is it easy to capture all of the positions of my entities (X, Y, Z, angles etc)? If so, can you give me a hint of how it can be done?
Thanks,
David
I am working on a machine simulator for bending sheet metal parts. I am thinking that I want the user to be able to set the machine settings for each bend on the sheet metal part and then click a button to save the settings. The sheet metal part can have many bends, so I need to be able to save many machine settings.
For example:
Image a box without a lid. It will have 5 sides...a left, right, back, front and bottom. To make a sheet metal box like that it will start off flat and look similar to a cross. If you fold up each of the 4 legs of the cross, you will end up with a 5 sided box.
So I have a "machine" programmed in Blitz that allows the user to import a flat sheet metal part from a CAD system. The user can move the flat part on the screen and also move parts of the machine around until the part and machine "fit" like the user wants. Once the machine setup is correct, I want the user to be able to click on a button that will "save" all of these positions...the part positions and machine positions. For each bend on the part, I will need to be able to save the part and machine positions.
Ultimately, I want to be able to recall these part and machine positions and play them back on the screen and maybe even change the order of the playback.
I feel confident that I can write a file to save this information but I need help with how to "Capture all of the positions so that I can write them to the file.
So...Is it easy to capture all of the positions of my entities (X, Y, Z, angles etc)? If so, can you give me a hint of how it can be done?
Thanks,
David