diff options
Diffstat (limited to 'src/post')
-rw-r--r-- | src/post/goom/convolve_fx.c | 8 | ||||
-rw-r--r-- | src/post/goom/motif_goom1.h | 7 | ||||
-rw-r--r-- | src/post/goom/motif_goom2.h | 7 |
3 files changed, 14 insertions, 8 deletions
diff --git a/src/post/goom/convolve_fx.c b/src/post/goom/convolve_fx.c index ee36dfd0b..ada619155 100644 --- a/src/post/goom/convolve_fx.c +++ b/src/post/goom/convolve_fx.c @@ -64,7 +64,7 @@ static void compute_tables(VisualFX *_this, PluginInfo *info) } } -static void set_motif(ConvData *data, Motif motif) +static void set_motif(ConvData *data, const Motif motif) { int i,j; for (i=0;i<CONV_MOTIF_W;++i) for (j=0;j<CONV_MOTIF_W;++j) @@ -100,7 +100,7 @@ static void convolve_init(VisualFX *_this, PluginInfo *info) { data->theta = 0; data->ftheta = 0.0; data->visibility = 1.0; - set_motif(data, CONV_MOTIF2); + set_motif(data, CONV_MOTIF2.motif); data->inverse_motif = 0; _this->params = &data->params; @@ -296,9 +296,9 @@ static void convolve_apply(VisualFX *_this, Pixel *src, Pixel *dest, PluginInfo switch (goom_irand(info->gRandom, 300)) { case 1: - set_motif(data, CONV_MOTIF1); data->inverse_motif = 1; break; + set_motif(data, CONV_MOTIF1.motif); data->inverse_motif = 1; break; case 2: - set_motif(data, CONV_MOTIF2); data->inverse_motif = 0; break; + set_motif(data, CONV_MOTIF2.motif); data->inverse_motif = 0; break; } } diff --git a/src/post/goom/motif_goom1.h b/src/post/goom/motif_goom1.h index b4a9f3f1d..0a40a35c2 100644 --- a/src/post/goom/motif_goom1.h +++ b/src/post/goom/motif_goom1.h @@ -1,4 +1,7 @@ -static Motif CONV_MOTIF1 = { +static const union { + const char u8[sizeof(Motif)]; + const Motif motif; +} CONV_MOTIF1 = {{ 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, @@ -1023,4 +1026,4 @@ static Motif CONV_MOTIF1 = { 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15 - }; + }}; diff --git a/src/post/goom/motif_goom2.h b/src/post/goom/motif_goom2.h index 4bde2a3d0..2d507c9dd 100644 --- a/src/post/goom/motif_goom2.h +++ b/src/post/goom/motif_goom2.h @@ -1,4 +1,7 @@ -static Motif CONV_MOTIF2 = { +static const union { + const char u8[sizeof(Motif)]; + const Motif motif; +} CONV_MOTIF2 = {{ 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, @@ -1023,4 +1026,4 @@ static Motif CONV_MOTIF2 = { 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15, 15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15 - }; + }}; |