Conversion of .SLDDRW(solidworks) into .IGES (.IGS) - file-format

How to save SolidWorks 2D drownings (.SLDDRW) into IGES file.
I know how to conwert 3D drownings, but in 2D there is no IGES in Save As.
Should be some way because at the begining IGES was created for 2D.

IGES can be exported only from part or assemblies. I'd suggest the following workaround:
Save a drawing in DXF/DWG format.
Open saved DXF/DWG file.
In DXF/DWG Import dialog select radio button 'Import to a new part as' and either option under it.
Press Finish button. A new part or assembly should be created.
Now you can export in IGES format. Just make sure that in IGES Export options 'IGES wireframe (3D curves)' is checked.
Good luck!

Related

macro for automatic refresh function on array

I am creating a dynamic reporting tool that creates reports from data sourced from Wonderware. The data that is sourced is gathered from various pumps/flows/temps around site for operators/management to use. I want to create a dynamic sheet rather than use the wizards available because of limited IT experience of some of the operators.
I have managed to create the report but have one issue that i cannot resolve that would help the sheet become more user friendly.
I have some array formulas that link to cells that have dropdowns. (This is what helps make it user friendly). The drop down cells include, which server to look at, which tagname to look for, the start time, the duration and the number of cells in the array.
When changing the number of cells in the array cell dropdown the array doesnt change until you select a cell in within the array and then select the Refresh Function command. This then changes the array.
I want to write a macro that will select several cells on the sheet that have individual arrays and select Refresh Function command. I will then assign this to a shape that can quickly and easily be selected.
Can anyone help with this macro please?
You just need to add the reference to ActiveFactoryWorkbook in visual basic editor, and then something like this:
Range("B11").Activate
ActiveFactoryWorkbook.wwRefreshFunction
Be sure that in the cell B11 you will have a part of the array the query generates. As you have to refresh more than one array just copy the code again and change the cell reference.
Sub Workbook_RefreshAll()
ActiveWorkbook.RefreshAll
End Sub

scn file all items rotated

I have a curtain I want to render in my ARKit app. I added all parts of my curtain (exported as COLLADA) and added them in my .scn file and placed them so that they line up properly and form a correct curtain.
Now I have added the file to the ARKit testing app and it seems like all individual objects rotated around the X-axis of their own coordinate system.
Why is this? Does it have something to do with Y vs Z being up?
Blender's coordinate system uses Z-up, but SceneKit uses Y-up. I believe that's where your issue is stemming from.
SCNScene has an initializer with loading options, try using the convertToYUp option. This could be done at runtime or before with a custom command line tool.
Here's an example of how to load a Collada file with the convert Y-up option, then exported to the url destination of your choice.
let scene = try? SCNScene(url: daeURL, options: [.convertToYUp: true])
scene.write(to: scnURL, options: nil, delegate: nil, progressHandler: nil)
I've been very happy with the results. SceneKit is able to convert not just single objects but multiple objects in complex scenes.
Just remember to apply rotation in Blender before exporting to get good results. I believe the hotkey to apply rotation is Ctrl+A, then R.

Converting .3DC + .DDS files into .OBJ + .MTL + .TGA

How would I go at converting .3DC + .DDS files into .OBJ + .MTL + .TGA?
This is actually very simple to do, this goes for mostly any file format but for this I'll be using .3DC file. Download 3D Object Converter, you'll have to pay a fee if you want the program to completely convert your object without removing every 5th quad or triangle. After you've done that open it and go into the menu and click batch convert. Add your file you want to convert change the options so that they suit you and choose the export for .obj Wavefront don't take any other type of .obj file format. You can find it near the end of the list. Then convert the file. And voila!
If your texture is in dds format or whatever and you want to change it to tga, just use an online picture converter.
After that amend the file.mtl and change to the correct texture it should call to.
And there you go!

Cut a jpg file in C, (NOT crop)

i would like to know how can i cut a jpg file using a coordinates i want to retrieve using artoolkit and opencv, see:
Blob Detection
i want to retrieve coordinates of the white sheet and then use those coordinates to cut a jpg file I'm took before.
Find this but how can this help?
How to slice/cut an image into pieces
If you already have the coordinates, you might want to deskew the image first:
http://nuigroup.com/?ACT=28&fid=27&aid=1892_H6eNAaign4Mrnn30Au8d
This post uses cv::warpPerspective() to achieve that effect.
The references above use the C++ interface of OpenCV, but I'm sure you are capable of converting between the two.
Second, cutting a particular area of an image is known as extracting a Region Of Interest (ROI). The general procedure is: create a CvRect to define your ROI and then call cvSetImageROI() followed by cvSaveImage() to save it on the disk.
This post shares C code to achieve this task.

display mat file in matlab

I want to display mat file's content to see all the results. I know that I can load it and then double click on it the content are display in the workspace, this case happen when the mat file content few information but when I have mat file content information for more than 13000 record I can't display it. could please any one help me to find any way to display mat file as table?
thanks
I do not know the format of your data (multi-dimensional, structs, cell-arrays), but there is a function called "openvar" which can be very useful for these things.
Let's define a large random 500x500x10 3d-matrix:
large = rand(500,500,10);
This variable contains 2.5 million double-values and takes up close to 20MB of memory. Opening this in the variable editor by double click in the Workspace window on "large" will usually (atleast on my system) give the following message:
"Cannot display summaries of variables with more than 524288 elements."
But you can use the "openvar"-function to open certain parts:
openvar('large(:,:,1)'); %# pass the argument as a string.
This will open the first "layer" of matrices in your Variable Editor (a 500x500 matrix in this case). This is useful if you need to look into certain parts of a large variable.
Of course you can always define new variables that contain subsets of your larger variable:
less_large = large(:,:,1);
... and then open "less_large" in the variable editor by double clicking on it in the workspace-window. But sometimes the "openvar"-method is a bit faster/easier.
You have a few options. Starting from a clear workspace, you could load the mat file into the workspace. Anything now in the workspace is in the mat file. You can use the variable viewer or parse with scripts.
If you have the Simulink toolbox, you can use Simulink.saveVars to save the contents of the workspace to a human readable m-script that would generate the same contents. It's a shame that you need Simulink to do this, as this function has nothing to do with Simulink.
How about after loading the data, and use whos to display the variables in current workspace? Note that you may want to clear all the other variables before displaying them.

Resources