| name | rvt-to-ifc |
| description | Convert RVT files to IFC format. Support IFC2x3, IFC4, IFC4.3 with customizable export settings. |
RVT to IFC Conversion
Note: RVT is the file format. IFC is an open standard by buildingSMART International.
Business Case
Problem Statement
IFC is the open BIM standard for interoperability, but:
- Native Revit IFC export requires Autodesk license
- Export settings significantly affect data quality
- Batch processing is manual and time-consuming
Solution
RVT2IFCconverter.exe converts Revit files to IFC offline, without licenses, with full control over export settings.
Business Value
- No license required - Works without Autodesk software
- Multiple IFC versions - IFC2x3, IFC4, IFC4.3 support
- Batch processing - Convert thousands of files
- Consistent quality - Standardized export settings
Technical Implementation
CLI Syntax
RVT2IFCconverter.exe <input.rvt> [<output.ifc>] [preset=<name>] [config="..."]
IFC Versions
| Version | Use Case |
|---|
| IFC2x3 | Legacy compatibility, most software |
| IFC4 | Enhanced properties, modern BIM |
| IFC4.3 | Infrastructure, latest standard |
Export Presets
| Preset | Description |
|---|
standard | Default balanced export |
extended | Maximum detail and properties |
custom | User-defined configuration |
Examples
RVT2IFCconverter.exe "C:\Projects\Building.rvt"
RVT2IFCconverter.exe "C:\Projects\Building.rvt" preset=extended
RVT2IFCconverter.exe "C:\Projects\Building.rvt" "D:\Export\model.ifc"
RVT2IFCconverter.exe "C:\Projects\Building.rvt" config="ExportBaseQuantities=true; SitePlacement=Shared"
Python Integration
import subprocess
from pathlib import Path
from typing import List, Optional, Dict, Any
from dataclasses import dataclass
from enum import Enum
class IFCVersion(Enum):
"""IFC schema versions."""
IFC2X3 = "IFC2x3"
IFC4 = "IFC4"
IFC4X3 = "IFC4x3"
class ExportPreset(Enum):
"""Export presets."""
STANDARD = "standard"
EXTENDED = "extended"
CUSTOM = "custom"
@dataclass
class IFCExportConfig:
"""IFC export configuration."""
ifc_version: IFCVersion = IFCVersion.IFC4
export_base_quantities: bool = True
site_placement: str = "Shared"
split_walls_and_columns: bool = False
include_steel_elements: bool = True
export_2d_elements: bool = False
export_linked_files: bool = False
export_rooms: bool = True
export_schedules: bool = True
def () -> :
parts = [
,
,
,
,
,
,
]
.join(parts)
:
():
.converter = Path(converter_path)
.converter.exists():
FileNotFoundError()
() -> Path:
rvt_path = Path(rvt_file)
rvt_path.exists():
FileNotFoundError()
cmd = [(.converter), (rvt_path)]
output_path:
cmd.append(output_path)
cmd.append()
config:
cmd.append()
result = subprocess.run(cmd, capture_output=, text=)
result.returncode != :
RuntimeError()
output_path:
Path(output_path)
rvt_path.with_suffix()
() -> [[, ]]:
folder_path = Path(folder)
results = []
rvt_file folder_path.glob():
:
output_folder:
out_dir = Path(output_folder)
out_dir.mkdir(parents=, exist_ok=)
output_path = (out_dir / rvt_file.with_suffix().name)
:
output_path =
ifc_path = .convert((rvt_file), output_path, preset, config)
results.append({
: (rvt_file),
: (ifc_path),
:
})
()
Exception e:
results.append({
: (rvt_file),
: ,
: ,
: (e)
})
()
results
() -> [, ]:
ifc_path = Path(ifc_file)
ifc_path.exists():
{: , : }
file_size = ifc_path.stat().st_size
file_size < :
{: , : }
(ifc_file, , errors=) f:
header = f.read()
header:
{: , : }
version =
header:
version =
header:
version =
header:
version =
{
: ,
: file_size,
: version
}
:
():
.converter = converter
() -> [, ]:
results = {}
preset [ExportPreset.STANDARD, ExportPreset.EXTENDED]:
:
output = Path(rvt_file).with_suffix()
.converter.convert(rvt_file, (output), preset)
validation = .converter.validate_output((output))
results[preset.value] = {
: validation.get(, ),
: validation.get(, )
}
Exception e:
results[preset.value] = {: (e)}
results
() -> :
converter = RevitToIFCConverter(converter_path)
output = converter.convert(rvt_file)
(output)
() -> []:
converter = RevitToIFCConverter(converter_path)
results = converter.batch_convert(folder)
[r[] r results r[] == ]
Quick Start
converter = RevitToIFCConverter("C:/DDC/RVT2IFCconverter.exe")
ifc = converter.convert("building.rvt")
print(f"Created: {ifc}")
config = IFCExportConfig(
ifc_version=IFCVersion.IFC4,
export_base_quantities=True,
export_rooms=True
)
ifc = converter.convert("building.rvt", preset=ExportPreset.CUSTOM, config=config)
Common Use Cases
1. Batch Processing
converter = RevitToIFCConverter()
results = converter.batch_convert(
folder="C:/Projects",
output_folder="C:/IFC_Export",
preset=ExportPreset.EXTENDED
)
print(f"Converted {len([r for r in results if r['status'] == 'success'])} files")
2. Quality Check
validation = converter.validate_output("model.ifc")
print(f"Valid: {validation['valid']}, Version: {validation['ifc_version']}")
3. Compare Presets
checker = IFCQualityChecker(converter)
comparison = checker.compare_presets("building.rvt")
print(comparison)
Resources