Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Георгий Носов
assignment-3-image-transform
Commits
56ef8820
Commit
56ef8820
authored
1 week ago
by
Deviantedh
Browse files
Options
Download
Email Patches
Plain Diff
Применение правок 1.4
parent
50c0d6d6
master
No related merge requests found
Pipeline
#120023
failed with stages
in 12 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
solution/src/transform.c
solution/src/transform.c
+5
-3
No files found.
solution/src/transform.c
View file @
56ef8820
...
...
@@ -4,10 +4,12 @@
typedef
void
(
*
transform_rule
)(
size_t
*
dest_x
,
size_t
*
dest_y
,
size_t
src_x
,
size_t
src_y
,
size_t
width
,
size_t
height
);
static
struct
image
create_image
(
size_t
width
,
size_t
height
)
{
struct
image
img
=
{
.
width
=
width
,
.
height
=
height
};
struct
image
create_image
(
uint32_t
width
,
uint32_t
height
)
{
struct
image
img
;
img
.
width
=
width
;
img
.
height
=
height
;
img
.
data
=
malloc
(
width
*
height
*
sizeof
(
struct
pixel
));
if
(
img
.
data
==
NULL
)
{
if
(
!
img
.
data
)
{
img
.
width
=
img
.
height
=
0
;
}
return
img
;
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Projects
Groups
Snippets
Help