  We consider a Riesz $\phi$-variation for functions $f$ defined on the real
line when $\varphi:\Omega\times[0,\infty)\to[0,\infty)$ is a generalized
$\Phi$-function. We show that it generates a quasi-Banach space and derive an
explicit formula for the modular when the function $f$ has bounded variation.
The resulting $BV$-type energy has previously appeared in image restoration
models. We generalize and improve previous results in the variable exponent and
Orlicz cases and answer a question regarding the Riesz--Medvedev variation by
Appell, Bana\'s and Merentes [\emph{Bounded Variation and Around}, Studies in
Nonlinear Analysis and Applications, Vol. 17, De Gruyter, Berlin/Boston, 2014].
