Mercurial > mplayer.hg
comparison libmpcodecs/vf_hue.c @ 29263:0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
author | diego |
---|---|
date | Wed, 13 May 2009 02:58:57 +0000 |
parents | a7b4da3584ca |
children | 391e683541a7 |
comparison
equal
deleted
inserted
replaced
29262:7d545a6b8aff | 29263:0f1b5b68af32 |
---|---|
63 mp_image_t *dmpi; | 63 mp_image_t *dmpi; |
64 | 64 |
65 dmpi=vf_get_image(vf->next, mpi->imgfmt, | 65 dmpi=vf_get_image(vf->next, mpi->imgfmt, |
66 MP_IMGTYPE_EXPORT, 0, | 66 MP_IMGTYPE_EXPORT, 0, |
67 mpi->w, mpi->h); | 67 mpi->w, mpi->h); |
68 | 68 |
69 dmpi->planes[0] = mpi->planes[0]; | 69 dmpi->planes[0] = mpi->planes[0]; |
70 dmpi->stride[0] = mpi->stride[0]; | 70 dmpi->stride[0] = mpi->stride[0]; |
71 dmpi->stride[1] = mpi->stride[1]; | 71 dmpi->stride[1] = mpi->stride[1]; |
72 dmpi->stride[2] = mpi->stride[2]; | 72 dmpi->stride[2] = mpi->stride[2]; |
73 | 73 |
74 if (!vf->priv->buf[0]){ | 74 if (!vf->priv->buf[0]){ |
75 vf->priv->buf[0] = malloc(mpi->stride[1]*mpi->h >> mpi->chroma_y_shift); | 75 vf->priv->buf[0] = malloc(mpi->stride[1]*mpi->h >> mpi->chroma_y_shift); |
76 vf->priv->buf[1] = malloc(mpi->stride[2]*mpi->h >> mpi->chroma_y_shift); | 76 vf->priv->buf[1] = malloc(mpi->stride[2]*mpi->h >> mpi->chroma_y_shift); |
77 } | 77 } |
78 | 78 |
79 if (vf->priv->hue == 0 && vf->priv->saturation == 1){ | 79 if (vf->priv->hue == 0 && vf->priv->saturation == 1){ |
80 dmpi->planes[1] = mpi->planes[1]; | 80 dmpi->planes[1] = mpi->planes[1]; |
81 dmpi->planes[2] = mpi->planes[2]; | 81 dmpi->planes[2] = mpi->planes[2]; |
82 }else { | 82 }else { |
83 dmpi->planes[1] = vf->priv->buf[0]; | 83 dmpi->planes[1] = vf->priv->buf[0]; |
84 dmpi->planes[2] = vf->priv->buf[1]; | 84 dmpi->planes[2] = vf->priv->buf[1]; |
85 process(dmpi->planes[1], dmpi->planes[2], | 85 process(dmpi->planes[1], dmpi->planes[2], |
86 mpi->planes[1], mpi->planes[2], | 86 mpi->planes[1], mpi->planes[2], |
87 dmpi->stride[1],mpi->stride[1], | 87 dmpi->stride[1],mpi->stride[1], |
88 mpi->w>> mpi->chroma_x_shift, mpi->h>> mpi->chroma_y_shift, | 88 mpi->w>> mpi->chroma_x_shift, mpi->h>> mpi->chroma_y_shift, |
89 vf->priv->hue, vf->priv->saturation); | 89 vf->priv->hue, vf->priv->saturation); |
90 } | 90 } |
91 | 91 |
92 return vf_next_put_image(vf,dmpi, pts); | 92 return vf_next_put_image(vf,dmpi, pts); |
93 } | 93 } |
149 { | 149 { |
150 vf->control=control; | 150 vf->control=control; |
151 vf->query_format=query_format; | 151 vf->query_format=query_format; |
152 vf->put_image=put_image; | 152 vf->put_image=put_image; |
153 vf->uninit=uninit; | 153 vf->uninit=uninit; |
154 | 154 |
155 if(!vf->priv) { | 155 if(!vf->priv) { |
156 vf->priv = malloc(sizeof(struct vf_priv_s)); | 156 vf->priv = malloc(sizeof(struct vf_priv_s)); |
157 memset(vf->priv, 0, sizeof(struct vf_priv_s)); | 157 memset(vf->priv, 0, sizeof(struct vf_priv_s)); |
158 } | 158 } |
159 if (args) sscanf(args, "%f:%f", &vf->priv->hue, &vf->priv->saturation); | 159 if (args) sscanf(args, "%f:%f", &vf->priv->hue, &vf->priv->saturation); |