Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options answers only not deleted user 4847
1 vote

Invalid or Unsupported format - pset4 (resize)

There are a number of errors in the code. It creates struct vars for the input file headers and reads the headers from the input file (correct), but then creates two more headers and reads again from …
Cliff B's user avatar
  • 69.3k
0 votes

pset4: Resize no error seen when compiling still unsupported image format

There's one major problem: After creating the header structs bof and boi, you don't populate them. A couple of fields are calculated, but the bulk of the fields are just garbage data. Structures can …
Cliff B's user avatar
  • 69.3k
1 vote
Accepted

pset4 resize, file format problem before resizing

Perhaps you should very carefully review the header fields that you are changing. Many have quite similar names, even the same name in both bi and bf headers. You should also use the peek tool to ex …
Cliff B's user avatar
  • 69.3k
2 votes
Accepted

pset4- recover invalid or unsupported image format

Look at the following code: fwrite(inptr, 512, 1, img); Why are you writing something back to the input file? Even if it was supposed to go to the output file, why would the same block be writ …
Cliff B's user avatar
  • 69.3k
1 vote
Accepted

Problem with CS50 Pset3 Resize Less

Hmmm..... After the code creates the output file headers, do you think it would be useful to load/copy the values from the input file headers into the output file headers? // write outfile's BITMAP …
Cliff B's user avatar
  • 69.3k
0 votes

CS50/PSET4/RECOVER- Error- "Can't open card.raw: file format unsupported"

The first problem I see is that "card.raw" is hardcoded. The spec says to use that the first input parameter should be the name of the input file, not that it should be hardcoded. But that's not your …
Cliff B's user avatar
  • 69.3k