I have not used motion detection on cameras yet thought it's on my wish list. There are several elements that must work together to get what you want. First, you need a camera that provides a feed to some kind of processor. The processor then reviews the frames to determine if whatever your motion criteria is exceeded and triggers a motion alert. That alert needs to be fed to a module in HG that is watched by either the security APP or something else that will process it and send the email.
It sounds like you are using an IP camera for your video source. Does the camera have built-in motion detection (some do, most don't AFAIK). If it does not, then you will need to have some system set up to watch that feed. If you use an RPi, be aware that the processing is fairly resource intensive. I played with Blue Iris for Windows and it worked, but that was running on a full PC not a relatively low powered RPi. If you want to use an RPi, you will most likely need to have a dedicated one for that processing (maybe one per feed, I don't know). MotionPi is one of the software I read about but never looked into. From reading, it looked like it would work quite well.
Whatever your processing solution is, you need to be able to send a signal to HG on motion start and stop. If you use an RPi or Windows, you could install HG on that system and send a command from one to the other as one option. Or, you could call the correct web page from your HG system using the API approach (see the other thread).
Once HG sees the motion, you need HG to do something with it. The security APP can send an email alert on trigger. If you don't like that, you could write your own small script that will do the same thing. I believe the other thread included a snippet of code to send the email. To make that work, you simply need a WhenModuleIsChanging command looking for your motion sensor module and send the email when the sensor turns on.