Questions tagged [rgbtriple]
The rgbtriple tag has no usage guidance.
7
questions
-1
votes
1
answer
47
views
CS50 Pset 4 edges: Why do I keep getting segmentation fault?
Please help me figure out what's wrong! I've been doing this pset for so long now, and I feel like everthing should work, But I just get a seg fault! The code looks like...
void edges(int height, int ...
0
votes
1
answer
154
views
Lab 4 Smiley - I can't change the color of pixels
#include "helpers.h"
void colorize(int height, int width, RGBTRIPLE image[height][width])
{
// Change all black pixels to a color of your choosing
for (int i = 0; i < height; i++)...
0
votes
1
answer
145
views
pset4 - (Filter Less ) - Doubts with malloc()
I'm performing the problem set from pset4 to the (filter less) part. I wish to use malloc() to my advantage to speed up image filtering and maybe check50 will accept my solution to the problem.
I ...
0
votes
1
answer
412
views
How does RGBTRIPLE differentiate between the 3 bytes it reads from input file and assign them to rgbt blue, green and red?
sorry if the question is confusing, but i completed the whodunit problem in pset3 and my doubt was that in the following code:
// iterate over pixels in scanline
for (int j = 0; j < bi....
2
votes
1
answer
3k
views
How does “RGBTRIPLE triple;” know whitch pixel to store?
I'm currently working on the cs50 pset4. My question is pretty straight forward: How does the line (marked with caps lock comment) "RGBTRIPLE triple;" knows whicht pixel currently to store? I get the ...
0
votes
1
answer
118
views
pset 4, resize.c is not working
Here is the code for resize.c I am stuck for quite some time now and i am not able to figure out where i am wrong. please help.
bi.biHeight = height*n;
bi.biWidth = width*n;
// determine new padding ...
2
votes
2
answers
4k
views
Why is RGBTRIPLE in our bitmap 3 bytes? Is that defined somewhere?
This question was asked in the comments of another question, and I think it's a good question, but I wanted to make sure this was addressed in the proper place:
How do I know RGB triple is 3 bytes? ...