Welcome to the Plugin Café forum and the Cinema 4D development community, it is great to have you with us!
Before creating your next postings, we would recommend making yourself accustomed with our Forum and Support Guidelines, as they line out details about the Maxon SDK Group support procedures. Of special importance are:
About your First Question
:warning: The major problem with your first question is that it is missing essential information. Please have a look at Structure of a Question and Forum Structure and Features.
- Share your code
- Tag your posting with programming language, OS version, and c4d version
- Clarify what constitutes as "doesn't work" for you here
- Line out what is a "real time PostEffect" for you, because there are two ways to achieve what could be considered "real time".
I can only speculate here due to the lack of code and additional information, but I would suspect your problems being tied to the fact that the viewport drawing API did change internally since R23. There can also other things come into play such as colliding IDs, but I cannot spend here pages on what you might be doing. Please provide sufficient information to answer your question.
ViewportRenderIDMessageData::viewportId is used to register your viewport effect, you must pass here a char sequence which uniquely identifies your plugin.
Our example you quoted is not written too well in that regard, because "invert" is a poor ID choice, it should be at least
"ID_INVERTVIDEOPOST", the symbol for the plugin ID. That is what we did internally in the past, here the material type
Mmaterial is for example registering its effect:
The quoted example is also missing the GL implementation of the effect in the first place.