Question: Please complete the following C + + code section. Please note that this C + + file is only a function module that is called,
Please complete the following C code section. Please note that this C file is only a function module that is called, so there is no need for a main function.
Do not add or change the header file after #incluede
#include "includesandconstants.h
Example function
void verticalflipconst float imageIMAGESIZE float flippedimageIMAGESIZE
for int i ; i IMAGESIZE; i
for int j ; j IMAGESIZE; j
flippedimageij imageIMAGESIZE ij;
;
;
TODO
void horizontalflipconst float imageIMAGESIZE float flippedimageIMAGESIZE
This function flips an x image horizontally.
Inputs:
image: a D array of size x representing the pixel values of the image.
Each element in the array corresponds to a pixel in the image.
Outputs via argument:
flippedimage: a D array of size x It is the result of horizontally
flipping the input image.
Example:
If the input image is:
then the result flippedimage should be:
Your TODO: Implement this function by looping through the flippedimage
and assign them pixel values from corresponding position of the image array.
TODO
void rotateconst float imageIMAGESIZE float flippedimageIMAGESIZE
This function rotates an x image degrees clockwise.
Inputs:
image: a D array of size x representing the pixel values of the image.
Each element in the array corresponds to a pixel in the image.
Outputs via argument:
flippedimage: a D array of size x This is the result of rotating
an x image degrees clockwise.
Example:
If the input image is:
then the result flippedimage should be:
Your TODO: Implement this function by looping through the flippedimage
and assign them pixel values from corresponding positions of the image array.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
