Skip to content

unify uniform grid and sample filters#1661

Open
nicolemarsaglia wants to merge 71 commits intodevelopfrom
task/2026_01_unify_uniform_grid_and_sample_filters
Open

unify uniform grid and sample filters#1661
nicolemarsaglia wants to merge 71 commits intodevelopfrom
task/2026_01_unify_uniform_grid_and_sample_filters

Conversation

@nicolemarsaglia
Copy link
Contributor

Add the uniform grid sampling filter into the larger sample filter (points, line, box).

Rename the viskoresProbe output field "HIDDEN" to "valid_mask"

Initial ANARI development via VTKm/Viskores
remove this check for now while we test and decide how to design things. 

anari vs. anari_vol & anari_pseudo & anari_points(?) idk all their renderers
@cyrush
Copy link
Member

cyrush commented Feb 23, 2026

Q: If someone still has an actions file that uses uniform_grid instead of sample, will this translate the args from that into the new filters?

@nicolemarsaglia
Copy link
Contributor Author

Q: If someone still has an actions file that uses uniform_grid instead of sample, will this translate the args from that into the new filters?

No, my plan was to remove it as a standalone filter, but the args are the same. I need to update the docs and examples.

@cyrush
Copy link
Member

cyrush commented Feb 23, 2026

I think it would be good to still support it. If the args are the same, "uniform_grid" can be added as an alias for "sample", we can do it with slight of hand.

@cyrush
Copy link
Member

cyrush commented Mar 3, 2026

For our test cases, we should have at least one that uses filter type uniform_grid instead of sample, b/c I believe that is the old incantation.

@cyrush
Copy link
Member

cyrush commented Mar 3, 2026

Looks good! See a few suggestions

else //not set; default min
{
x_min = g_bounds.X.Min;
x_min = min_b["x"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets use to_float64() to be safe (folks may pass ints)

else
{
y_min = g_bounds.Y.Min;
y_min = min_b["y"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
y_min = min_b["y"].as_float64();
y_min = min_b["y"].to_float64();

else //not set; default min
{
x_min = g_bounds.X.Min;
x_min = min_b["x"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
x_min = min_b["x"].as_float64();
x_min = min_b["x"].to_float64();

else
{
z_min = g_bounds.Z.Min;
z_min = min_b["z"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
z_min = min_b["z"].as_float64();
z_min = min_b["z"].to_float64();

else
{
x_max = g_bounds.X.Max;
x_max = max_b["x"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
x_max = max_b["x"].as_float64();
x_max = max_b["x"].to_float64();

else
{
y_max = g_bounds.Y.Max;
y_max = max_b["y"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
y_max = max_b["y"].as_float64();
y_max = max_b["y"].to_float64();

else
{
z_max = g_bounds.Z.Max;
z_max = max_b["z"].as_float64();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
z_max = max_b["z"].as_float64();
z_max = max_b["z"].to_float64();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants