I’m trying to create an operator that lets the user set the position of the viewport camera to match that of another viewport. Basically, I want to user to start the operator in one viewport, click on the other viewport they want to copy the view from and then update the
context.region_data.view_matrix to match that of the second viewport.
I suspect that the information I need is buried in the
context parameter passed into the
modal() method, but I cannot find any documentation on what exactly this object contains. Is there a way for me to capture the
region_data.view_matrix of the second viewport I click on and then copy that into the
region_data.view_matrix of the viewport I started in?