Speckle is the data infrastructure for the AEC industry.
- Object-based: say goodbye to files! Speckle is the first object based platform for the AEC industry
- Version control: Speckle is the Git & Hub for geometry and BIM data
- Collaboration: share your designs collaborate with others
- 3D Viewer: see your CAD and BIM models online, share and embed them anywhere
- Interoperability: get your CAD and BIM models into other software without exporting or importing
- Real time: get real time updates and notifications and changes
- GraphQL API: get what you need anywhere you want it
- Webhooks: the base for a automation and next-gen pipelines
- Built for developers: we are building Speckle with developers in mind and got tools for every stack
- Built for the AEC industry: Speckle connectors are plugins for the most common software used in the industry such as Revit, Rhino, Grasshopper, AutoCAD, Civil 3D, Excel, Unreal Engine, Unity, QGIS (you are here), Blender and more!
Give Speckle a try in no time by:
- for help, feature requests or just to hang with other speckle enthusiasts, check out our community forum!
- our tutorials portal is full of resources to get you started using Speckle
- reference on almost any end-user and developer functionality
This repo contains the QGIS plugin for Speckle 2.0. It is written in python
and uses our fantastic Python SDK. The Speckle Server is providing all the web-facing functionality and can be found here.
Try it out!! Although we're still in early development stages, we encourage you to try out the latest stable release. Just follow the instructions on this file, and head to the Releases page to download the necessary files and dependencies.
What can it do?
Currently, the plugin allows to send data from a single layer to a Speckle server using one of the accounts configured on your computer. It will extract all the features of that layer along side their properties and, when possible, geometry too. The following geometry types are supported for now:
- Point
- Multipoint
- Polyline (LineString)
- MultiLineString
- Polygon
- MultiPolygon
- More to come!!
If you have questions, you can always find us at our Community forum
You can find Speckle QGIS in the QGIS Plugins -> Manage and install plugins
menu item.
The plugin is currently published as experimental, so make sure you go to Settings
and activate the Show also experimental plugins
checkbox.
Then go to the All
tab and search for Speckle
. You should see the plugin appear in the list:
You'll need to place the speckle_qgis
folder into your plugins folder. To find this folder, go to the "Settings" menu and select "User Profiles" > "Open Active Profile Folder".
Inside this folder, navigate into the python
folder then the plugins
folder. Once inside the plugins
folder, drop your speckle_qgis
folder into it.
You no longer need to take care of installing the dependencies! This will be done automatically if the package is not found.
You should now launch QGIS and you should see SpeckleQGIS in your installed plugins. Click the blue brick in the toolbar to open the plugin.
Setup is a bit cumbersome for now. The following is adapted from this tutorial
To edit the UI of the plugin, you'll want to install Qt creator. You can find the free installers on this page in the "Qt Creator" tab. On Windows, you'll be prompted to create an account during the installation process.
For Windows, the bindings are already included in the QGIS installation.
For Mac, you can install PyQt
using homebrew.
brew install pyqt
pb_tool
allows you to compile resource files from into something python will understand.
For this plugin we only have one file to convert:
resources.qrc
->resources.py
To install pb_tool
, just run:
pip install pb_tool
or
YOUR_PYTHON_EXECUTABLE -m pip install pb_tool
For convenience, the pre-compiled
resources.py
file so you don't really have to do anything here.
For a better development experience in your editor, we recommend creating a virtual environment. In the venv, you'll just need to install specklepy
. You will also need to copy over the qgis
module into the {venv}/Lib/site-packages
. You can find the qgis
module in your QGIS install directory:
- Windows:
C:\Program Files\QGIS 3.20.1\apps\qgis\python
- MacOS:
/Applications/QGIS.app/Contents/Resources/python
Though it is not required, we recommend installing these plugins from the QGIS Plugin Manager:
- Plugin Reloader (allows you to reload the plugin without restarting QGIS)
- Remote Debugger (enables interactive debugging)
- First Aid (shows errors before crashing QGIS, sometimes)
First, you'll need to uncomment these 2 lines in the __init__.py
file:
# from speckle.utils import enable_remote_debugging
# enable_remote_debugging()
This will automatically setup ptvsd
if it's not already installed, and start listening to port 5678
.
In VS Code, you can use the built in python debugger. You'll need to create a debug configuration by creating a launch.json
file.
Select the "Python" -> "Remote Attach" option. Your launch.json
should look like this:
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: Remote Attach",
"type": "python",
"request": "attach",
"port": 5678,
"host": "localhost",
"pathMappings": [
{
"localRoot": "${workspaceFolder}",
"remoteRoot": "${workspaceFolder}"
}
]
}
]
}
To start debugging, you'll need to first launch QGIS. Once it's running, run your debug Python: Remote Attach
configuration.
That's all there is to it! Now any breakpoints you create should be hit.
If you want to have the debugger wait for you to connect using VSCode, you can uncomment this line in the
speckle/utils.py
file:#ptvsd.wait_for_attach()
Enjoy!