# NeedToRenderForPicking(GameObject)

> Checks whether a GameObject should be rendered in the current render picking callback.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/6000.5/script-reference/unityeditor.md)
* **Assembly:** UnityEditor.CoreModule

```csharp
public bool NeedToRenderForPicking(GameObject go)
```

### Parameters

**** (\[GameObject]\(/engine/6000.5/script-reference/unityengine/gameobject)): The GameObject to test.

### Returns

| Type                                                          | Description                                |
| ------------------------------------------------------------- | ------------------------------------------ |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if the GameObject should be rendered. |

### Remarks

`RenderPickingArgs.NeedToRenderForPicking` is similar to [RenderObjectSetContains](/engine/6000.5/script-reference/unityeditor/renderpickingargs/renderobjectsetcontains.md). This method checks whether a GameObject should be rendered or not.

If the current [renderPickingType](/engine/6000.5/script-reference/unityeditor/renderpickingargs/renderpickingtype.md) is [RenderPickingType.RenderFromIgnoreSet](/engine/6000.5/script-reference/unityeditor/renderpickingtype/renderfromignoreset.md), this method returns true if the given `go` is not contained in the ignore set. Otherwise, this method returns true if the given `go` is contained in the filter set.

Notice that for the [RenderPickingType.RenderFromIgnoreSet](/engine/6000.5/script-reference/unityeditor/renderpickingtype/renderfromignoreset.md) type, this method returns true for all GameObjects if it is not contained in the ignore set. However, you are only required to handle the rendering of the custom geometries your callback is set to render.
