Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
837f3ba2
Commit
837f3ba2
authored
Jul 19, 2006
by
Antoine Cellerier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add some "const" where relevant
parent
cbe9f051
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
17 deletions
+17
-17
modules/video_filter/gradient.c
modules/video_filter/gradient.c
+17
-17
No files found.
modules/video_filter/gradient.c
View file @
837f3ba2
...
@@ -270,10 +270,10 @@ static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
...
@@ -270,10 +270,10 @@ static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
*****************************************************************************/
*****************************************************************************/
static
void
GaussianConvolution
(
picture_t
*
p_inpic
,
uint32_t
*
p_smooth
)
static
void
GaussianConvolution
(
picture_t
*
p_inpic
,
uint32_t
*
p_smooth
)
{
{
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
const
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
const
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
const
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
const
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
int
x
,
y
;
int
x
,
y
;
for
(
y
=
2
;
y
<
i_num_lines
-
2
;
y
++
)
for
(
y
=
2
;
y
<
i_num_lines
-
2
;
y
++
)
...
@@ -323,12 +323,12 @@ static void FilterGradient( filter_t *p_filter, picture_t *p_inpic,
...
@@ -323,12 +323,12 @@ static void FilterGradient( filter_t *p_filter, picture_t *p_inpic,
picture_t
*
p_outpic
)
picture_t
*
p_outpic
)
{
{
int
x
,
y
;
int
x
,
y
;
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
const
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
const
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
int
i_dst_pitch
=
p_outpic
->
p
[
Y_PLANE
].
i_pitch
;
const
int
i_dst_pitch
=
p_outpic
->
p
[
Y_PLANE
].
i_pitch
;
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
const
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
const
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
uint8_t
*
p_outpix
=
p_outpic
->
p
[
Y_PLANE
].
p_pixels
;
uint8_t
*
p_outpix
=
p_outpic
->
p
[
Y_PLANE
].
p_pixels
;
uint32_t
*
p_smooth
;
uint32_t
*
p_smooth
;
...
@@ -369,7 +369,7 @@ static void FilterGradient( filter_t *p_filter, picture_t *p_inpic,
...
@@ -369,7 +369,7 @@ static void FilterGradient( filter_t *p_filter, picture_t *p_inpic,
{ \
{ \
for( x = 1; x < i_src_visible - 1; x++ ) \
for( x = 1; x < i_src_visible - 1; x++ ) \
{ \
{ \
uint32_t a =
\
const uint32_t a =
\
( \
( \
abs( \
abs( \
( p_smooth[(y-1)*i_src_visible+x-1] \
( p_smooth[(y-1)*i_src_visible+x-1] \
...
@@ -457,12 +457,12 @@ static void FilterEdge( filter_t *p_filter, picture_t *p_inpic,
...
@@ -457,12 +457,12 @@ static void FilterEdge( filter_t *p_filter, picture_t *p_inpic,
{
{
int
x
,
y
;
int
x
,
y
;
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
const
int
i_src_pitch
=
p_inpic
->
p
[
Y_PLANE
].
i_pitch
;
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
const
int
i_src_visible
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_pitch
;
int
i_dst_pitch
=
p_outpic
->
p
[
Y_PLANE
].
i_pitch
;
const
int
i_dst_pitch
=
p_outpic
->
p
[
Y_PLANE
].
i_pitch
;
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
const
int
i_num_lines
=
p_inpic
->
p
[
Y_PLANE
].
i_visible_lines
;
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
const
uint8_t
*
p_inpix
=
p_inpic
->
p
[
Y_PLANE
].
p_pixels
;
uint8_t
*
p_outpix
=
p_outpic
->
p
[
Y_PLANE
].
p_pixels
;
uint8_t
*
p_outpix
=
p_outpic
->
p
[
Y_PLANE
].
p_pixels
;
uint32_t
*
p_smooth
;
uint32_t
*
p_smooth
;
...
@@ -518,14 +518,14 @@ static void FilterEdge( filter_t *p_filter, picture_t *p_inpic,
...
@@ -518,14 +518,14 @@ static void FilterEdge( filter_t *p_filter, picture_t *p_inpic,
for
(
x
=
1
;
x
<
i_src_visible
-
1
;
x
++
)
for
(
x
=
1
;
x
<
i_src_visible
-
1
;
x
++
)
{
{
int
gradx
=
const
int
gradx
=
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
-
1
]
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
-
1
]
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
-
1
]
)
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
-
1
]
)
+
(
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
]
+
(
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
]
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
]
)
<<
1
)
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
]
)
<<
1
)
+
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
+
1
]
+
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
+
1
]
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
+
1
]
);
-
p_smooth
[(
y
+
1
)
*
i_src_visible
+
x
+
1
]
);
int
grady
=
const
int
grady
=
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
-
1
]
(
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
-
1
]
-
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
+
1
]
)
-
p_smooth
[(
y
-
1
)
*
i_src_visible
+
x
+
1
]
)
+
(
(
p_smooth
[
y
*
i_src_visible
+
x
-
1
]
+
(
(
p_smooth
[
y
*
i_src_visible
+
x
-
1
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment