Megascans LiveLink in H21

   161   0   0
User Avatar
Member
201 posts
Joined: April 2009
Offline
Like most of you probably know, MSLiveLink used to work in Houdini up until H20.5 but since H21 it did not work anymore.
Even though Quixel Megascans is migrated to Fab, the Bridge App still works and personally, I prefer Bridge to browsing through all the paid stuff in Fab.
So what I did to fix it is not very complicated but I wanted to share that here with the community.

The issue is the fact that H21 switched to Qt6 and so PySide2 is not available anymore.
Since the python scripts in the MSLiveLink plugin use these you get errors.
The fix is easy:
If you have your MSPlugin installed you have to go to
MegascansBridge\support\plugins\houdini\4.6\MSLiveLink\scripts\python\MSPlugin
In there you'll find a bunch of .py files that all call on each other.
First MainWindow.py:
In the first lines you'll see this:
from PySide2 import QtGui
from PySide2 import QtCore
from PySide2.QtWidgets import QLabel, QWidget,QApplication, QVBoxLayout,QMainWindow

Change those to PySide6 and this file is done.
This file invokes OptionsUI.py and USDUI as well and later SocketListener.py as well, so we need to check all those as well but to be short: in all the .py files you find in this directory, scan for PySide2 and change it to PySide6

But that's not all.
In USDUI there are calls to QRegExp. This is deprecated since Qt5.15 and should be replaced by QRegularExpression.
The line(43) containing that code will look like this after you changed it:
self.refpathRegexp = QtCore.QRegularExpression("+")

There is also a call to QRegExpValidator and that one has also been replace, in this case by QRegularExpressionValidator
So, line 44 will be this:
refpathValidator = QtGui.QRegularExpressionValidator(self.refpathRegexp)

Save all the files, and lo an behold, your Megascans Livelink works like a charm again.

Hope this helps

Cheers,

Rudi
  • Quick Links