Skip to content

Optimize Use of videoEffects Vector #2

Description

@YedTheEmo
// in main loop:
videoEffects.resize(4);
videoEffects[g_FourIntCache.a - 1] = (chkBoxBlur == true) ? &boxBlur : nullptr;
videoEffects[g_FourIntCache.b - 1] = (chkVignette == true) ? &vignette : nullptr;
videoEffects[g_FourIntCache.c - 1] = (chkEdgeDetection == true) ? &edgeDetection : nullptr;
videoEffects[g_FourIntCache.d - 1] = (chkMonochrome == true) ? &monoChrome : nullptr;

resize(4) keeps getting called even when resizing is not required (i.e., no change in checkbox status).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions