This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<!DOCTYPE html>
|
||||
<!doctype html>
|
||||
<html lang="de">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
@@ -41,7 +41,13 @@
|
||||
];
|
||||
|
||||
const increaseBrightness = (image, value) => {
|
||||
// Your code here
|
||||
return image.map((row) =>
|
||||
//
|
||||
row.map((pixel) =>
|
||||
//
|
||||
pixel.map((idx) => Math.min(idx + value, 255)),
|
||||
),
|
||||
);
|
||||
};
|
||||
|
||||
const newImage = increaseBrightness(image, 30);
|
||||
|
||||
Reference in New Issue
Block a user