Can't get UIDetect work

  • Posts: 3
4 weeks 3 hours ago - 4 weeks 3 hours ago #1 by Fabu
Hi, I try a lot of things but I can't get the uidetection works, the effects just pass through the layer UIDetectMaskRGB as it shows:

Without the effect
https://ibb.co/T1k1zbc

With effect eneable, with a reset before
https://ibb.co/0f7MgfF

The only thing that "works" is the black area - UI desired - that is eneable by uimask_bottom
https://ibb.co/WtQGHcs

I noticed that when I eneable uidetect, it doesn't appear any option to adjust, nothing happens

Any help is appreciated!

Please Log in or Create an account to join the conversation.

  • Posts: 285
3 weeks 6 days ago #2 by brussell
First, UIMask is a seperate shader. UIDetect only uses UIDetect, UIDetect_Before, UIDetect_After and comes with it's own UIDetectMaskRGB.png.

Have you read the description ( github.com/brussell1/Shaders/blob/master/Shaders/UIDetect.fxh ) and followed it's steps?

Please Log in or Create an account to join the conversation.

  • Posts: 3
3 weeks 6 days ago #3 by Fabu
Hi Brussell,

Yes, I followed the description but I don't know what I'm missing... this is my UIDetect.fxh config

#define PIXELNUMBER 3

static const float3 UIPixelCoord[PIXELNUMBER]=
{
float3(40,8,1),
float3(39,7,1),
float3(84,4,1),

}
static const float3 UIPixelRGB[PIXELNUMBER]=
{
float3(0,0,0),
float3(212,203,196),
float3(192,184,144),
}
*/

This is the png image that I use for detection:
https://ibb.co/5241Dz7https://ibb.co/5241Dz7


and the effects order:
https://ibb.co/0f7MgfF

The pixel coordinates and color are based in this top left part of the screen (1920x1080)
https://ibb.co/T1k1zbc

Thanks!

Please Log in or Create an account to join the conversation.

  • Posts: 285
3 weeks 4 days ago #4 by brussell
Are you sure you set "UIDetect_USE_MASK" to true?
If yes, it could be possible that the color values you got from the screenshot don't match with the real ones. You can check this via "UIDetect_ShowPixel" (details in description) and edit the values accordingly.

Please Log in or Create an account to join the conversation.

  • Posts: 3
3 weeks 4 days ago - 3 weeks 4 days ago #5 by Fabu
About the first, yes, as the follow image:

https://ibb.co/VDSTWRT

I check the colors and coordinates in Photoshop and they are ok, but as you said in the instructions maybe there is some change ingame vs screenshot, so how I can eneable UIDetect_ShowPixel? it this an effect? because I don't find it in the library

"-UIDetect_ShowPixel must be the first and only effect in the load order when used"

Thanks in advance

Please Log in or Create an account to join the conversation.

  • Posts: 285
3 weeks 3 days ago - 3 weeks 3 days ago #6 by brussell
Yes, you should find UIDetect_ShowPixel in the list of effects. Once enabled, you can set the x and y position of the pixel for which you want to see the color.
Then take a screenshot and use a color picker tool in Photoshop to see the real RGB values.

Please Log in or Create an account to join the conversation.