Input/Output

class figura.io.IGESFile(file_name)

IGES file

Parameters:

file_name – The name of the IGES file

read()

Read the file

Returns:

The shape that is contained on the IGES file

write(shapes)

Write shapes into the file

Parameters:

shapes – List of shapes

class figura.io.STEPFile(file_name)

STEP file

Parameters:

file_name – The name of the STEP file

read()

Read the file

Returns:

The shape that is contained on the STEP file

write(shapes)

Write shapes into the file

Parameters:

shapes – List of shapes

class figura.io.STLFile(file_name, binary=True)

STL file

Parameters:
  • file_name – The name of the STL file

  • binary – True for binary format, False for ASCII

write(shapes)

Write shapes into the file

Parameters:

shapes – List of shapes

figura.io.export(file_name, shapes, file_format='step')

Deprecated. Use write instead.

Parameters:
  • file_name – File name

  • shapes – List of shapes

  • file_format – File format

Returns:

figura.io.read(file_name)

Read shapes from a file

Parameters:

file_name – Name of the file

Returns:

Shape(s) from the file

figura.io.write(file_name, shapes, file_format='step')

Write shapes into a file

Parameters:
  • file_name – Name of the file

  • shapes – List of shapes

  • file_format – File format [‘step’, ‘stl’, ‘iges’]