Jump to content

[HELP]About Metin2 RenderGame()


Go to solution Solved by Gurgarath,

Recommended Posts

Hi, im building some post processing filters and wanna implement shaders in the binary of the client. Im making good progress and i want to share my work with all of you, but im having just a single problem i cant solve. As you can see in the next img, im loading some basic filters from .fx file without problems:

.png

The issue im having right now is that the filter is rendering on ui too. I tried to divide game render and onuirender in PythonApplication.cpp, but i tried different ways to get the filter work just on render buffer without sucess. I have the binary updated to d9

PythonApplication.cpp
[...]
				CGraphicDevice::RenderPostProcess();
			}
			//post procesado end

			if (m_pyGraphic.Begin())
			{
				m_pyGraphic.ClearDepthBuffer();

#ifdef _DEBUG
				m_pyGraphic.SetClearColor(0.3f, 0.3f, 0.3f);
				m_pyGraphic.Clear();
#endif

				/////////////////////
				// Interface
				m_pyGraphic.SetInterfaceRenderState();

				OnUIRender();
				OnMouseRender();
				/////////////////////

				m_pyGraphic.End();

				//DWORD t1 = ELTimer_GetMSec();
				m_pyGraphic.Show();
				//DWORD t2 = ELTimer_GetMSec();

[...]


Where is the exact moment ui is start rendering? because it seems it is there. Maybe buffer is getting replaced but im sure is not. Any help from someone who have better knowledge about this?

Edited by Adddirl
Link to comment
https://metin2.dev/topic/33816-helpabout-metin2-rendergame/
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

  • Forum Moderator
  • Solution

Hello, my shaders' processing loop is in RenderGame() right after "m_pyBackground.RenderAfterLensFlare();" and they do not apply on the UI. 

Gurgarath
coming soon
My Services

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.