Update
This commit is contained in:
parent
07603f7b64
commit
9f8a2c5392
8 changed files with 1945 additions and 1935 deletions
6
cyber.md
6
cyber.md
|
@ -1,3 +1,7 @@
|
|||
# Cyber
|
||||
|
||||
*Cyber* (taken from [cybernetics](cybernetics.md), the theory of communication and control, coming from Greek *kybernetes*, *steersman*) is a word prefix that signifies a relation to [computers](computers.md), especially computer networks and the [Internet](internet.md). It is nowadays used mainly for relating old concept to the [modern](modern.md) world dominated by computers. By itself or as a verb "cyber" often signifies *cybersex*. Some terms using the prefix include [cybernetics](cybernetics.md), [cyberpunk](cyberpunk.md), [cybersex](cybersex.md), [cyberspace](cyberspace.md), [cybercrime](cybercrime.md), [cyberbullying](cyberbullying.md), [cyberculture](culture.md), [cyborg](cyborg.md), [cybersecurity](security.md) etc.
|
||||
*Cyber* (taken from [cybernetics](cybernetics.md), the theory of communication and control, coming from Greek *kybernetes*, *steersman*) is a word prefix that signifies a relation to [computers](computers.md), especially computer networks and the [Internet](internet.md). It is nowadays used mainly for relating old concept to the [modern](modern.md) world dominated by computers. By itself or as a verb "cyber" often signifies *cybersex*. Some terms using the prefix include [cybernetics](cybernetics.md), [cyberpunk](cyberpunk.md), [cybersex](cybersex.md), [cyberspace](cyberspace.md), [cybercrime](cybercrime.md), [cyberbullying](cyberbullying.md), [cyberculture](culture.md), [cyborg](cyborg.md), [cybersecurity](security.md) etc.
|
||||
|
||||
## See Also
|
||||
|
||||
- [digital](digital.md)
|
|
@ -1,6 +1,6 @@
|
|||
# Dodleston Mystery
|
||||
|
||||
The Dodleston mystery regards a teacher Ken Webster who in 1984 supposedly started exchanging messages with people from the past and future, most notably people from the 16th and 22nd century, via files on a [BBC micro](bbc_micro.md) computer. While probably a [hoax](hoax.md) and [creepypasta](creepypasta.md), there are some interesting unexplained details... and it's a fun story.
|
||||
The Dodleston mystery regards a teacher Ken Webster who in [1984](1984.md) (coincidence?) supposedly started exchanging messages with people from the past and [future](future.md), most notably ones from the 16th and 22nd century, via files on a [BBC micro](bbc_micro.md) [computer](computer.md). While probably a [hoax](hoax.md) and [creepypasta](creepypasta.md), there are some interesting unexplained details... and it's a [fun](fun.md) story.
|
||||
|
||||
The guy has written a [proprietary](proprietary.md) book about it, called *The Vertical Plane*.
|
||||
|
||||
|
|
40
exercises.md
40
exercises.md
|
@ -32,26 +32,28 @@ This place is for suggesting programming [projects](project.md) that will in fir
|
|||
4. **password generator**: Make a program which when run outputs randomly generated password (of course it must generate different password each time, i.e. you can't output the exact same password every time). The password must be at least 10 characters long, contain at least one English alphabet letter, one decimal digit and one special character.
|
||||
5. **rock, paper scissors**: Make a game of rock paper scissors, the player plays against the computer.
|
||||
6. **average**: Make a program that reads two numbers (you can assume only non-negative integers will be input) and writes out their average (it can be rounded, even to just integer, e.g. 3 and 8 can give 5).
|
||||
7. **kawaii filter**: Make a program that will filter input text to make it more kawai senpai. It has to read characters from input until end is reached (you can consider either EOF or end of line the end of input, that's up to you), outputting each character it reads as soon as it reads it, except for letters *r*/*R* that will be replaced with *w*/*W*. Also when period is read, the word *desu* must be output before it. For example the input *"This program is really good."* will produce output *"This pwogwam is weally good desu."*.
|
||||
8. **info tool**: Make a tool that will output some basic info about real world, the computer, its operating system or the programming language -- you have to really retrieve this info e.g. using standard library, OS files, language's built-in functions etc. When run, it has to output at least three of the following things: current time, current date, operating system name and version, programming language version, native integer size in bits, amount of computer RAM, free disk space, CPU name and/or frequency and/or number of cores or locale info (language, timezone, ...). (hints: see *time.h*, *limits.h*, *locale.h*, *man system* etc.)
|
||||
9. **[ASCII art](ascii_art.md) animation**: Program a simple ASCII art animation that will play in terminal -- just make a few frames of the animation in some text editor, then make a program that will show one frame after another. After each frame write out like 50 spaces to scroll the old frame away from the screen, then draw the next frame. The animation can be advanced just with a key press, i.e. you can just have a loop that draws the frames and at the end of the loop you just wait for user input (but thumbs up if you can figure out how to pause for some fixed time after each frame). Thumbs up: if you can do it, you can also generate the animation [procedurally](procgen.md), i.e. you can for example make an animation of expanding circle without having to draw it all by hand, but this is more difficult.
|
||||
10. **[Nim](nim.md)**: Implement the simple variant of the game Nim for two human players -- At the beginning there will be 15 matches, players take turns, in each turn a player can take 1, 2 or 3 matches. That who takes the last one loses. The game has to show the number of matches as a numeral and also graphically, for example: `|||||||||||||||`. Players have to input `1`, `2` or `3` to play their turn, on wrong input the game has to report error and ask again. At the end the winner must be reported. Thumbs up for randomly setting the initial number of matches between 10 and 15 or even making a simple AI (can even just make random choices).
|
||||
7. **dyslexia simulator**: Make a program that will read text (or any length) from the standard input, then output it on standard output so that each pair of letters will be swapped. For example when passed `hi everyone`, the program will output `ihe evyrnoe`.
|
||||
8. **kawaii filter**: Make a program that will filter input text to make it more kawai senpai. It has to read characters from input until end is reached (you can consider either EOF or end of line the end of input, that's up to you), outputting each character it reads as soon as it reads it, except for letters *r*/*R* that will be replaced with *w*/*W*. Also when period is read, the word *desu* must be output before it. For example the input *"This program is really good."* will produce output *"This pwogwam is weally good desu."*.
|
||||
9. **info tool**: Make a tool that will output some basic info about real world, the computer, its operating system or the programming language -- you have to really retrieve this info e.g. using standard library, OS files, language's built-in functions etc. When run, it has to output at least three of the following things: current time, current date, operating system name and version, programming language version, native integer size in bits, amount of computer RAM, free disk space, CPU name and/or frequency and/or number of cores or locale info (language, timezone, ...). (hints: see *time.h*, *limits.h*, *locale.h*, *man system* etc.)
|
||||
10. **[ASCII art](ascii_art.md) animation**: Program a simple ASCII art animation that will play in terminal -- just make a few frames of the animation in some text editor, then make a program that will show one frame after another. After each frame write out like 50 spaces to scroll the old frame away from the screen, then draw the next frame. The animation can be advanced just with a key press, i.e. you can just have a loop that draws the frames and at the end of the loop you just wait for user input (but thumbs up if you can figure out how to pause for some fixed time after each frame). Thumbs up: if you can do it, you can also generate the animation [procedurally](procgen.md), i.e. you can for example make an animation of expanding circle without having to draw it all by hand, but this is more difficult.
|
||||
11. **[Nim](nim.md)**: Implement the simple variant of the game Nim for two human players -- At the beginning there will be 15 matches, players take turns, in each turn a player can take 1, 2 or 3 matches. That who takes the last one loses. The game has to show the number of matches as a numeral and also graphically, for example: `|||||||||||||||`. Players have to input `1`, `2` or `3` to play their turn, on wrong input the game has to report error and ask again. At the end the winner must be reported. Thumbs up for randomly setting the initial number of matches between 10 and 15 or even making a simple AI (can even just make random choices).
|
||||
|
||||
### Level 1: Easy, *I'm Too Young To Die*
|
||||
|
||||
1. **[fizzbuzz](fizzbuzz.md)**: Write the classic fizzbuzz program.
|
||||
2. **[palindrome](palindrome.md) checker**: Make a program that reads one line of text from the user and checks if it's a palindrome (i.e. if it's spelled the same forward and backwards) or not -- you can just output *yes* or *no*. { I fucked up and had an "anagram" checker here before, I get the two confused, thanks to a reader for correction <3 ~drummyfish }
|
||||
3. **number [encyclopedia](encyclopedia.md)**: Make a program that writes numbers from 0 to 1000 (including both) and about each of which it writes some facts. These facts have to include at least the number's square, square root, sum of its decimal digits, its [binary](binary.md) representation, prime factorization and whether the number itself is [prime](prime.md), perfect number and [Fibonacci](fibonnaci.md) number.
|
||||
4. **[game of life](game_of_life.md)**: Make a program that simulates game of life on a finite *N * N* grid, with wrapping space (i.e. a cell on the very left of the grid is considered a neighbor of the cell on the very right in the same row, same thing with top and bottom). Make *N* configurable at least as a compile time option, draw the world as [ASCII art](ascii_art.md) to terminal, make the user step forward by pressing some key. You can initialize the grid values randomly, but thumbs up for allowing setting the initial world state (e.g. reading it from a file or something).
|
||||
5. **[anagram](anagram.md) checker**: Make a program that reads two words and checks if they are an anagram of each other or not (i.e. one can be made from the other just by rearranging the letters). You can just output *yes* or *no*.
|
||||
6. **text adventure**: Make an interactive [CLI](cli.md) text adventure that will take an average player at least 10 minutes to finish. Part of game mechanics must involve inventory, i.e. picking up items, carrying them around and using them.
|
||||
7. **calculator**: Make an interactive calculator -- it can be a purely [command line](cli.md) program into which user types expressions and your program evaluates them. The functionality must be at least on the level of the most plain physical calculators, i.e. it doesn't have to parse whole complex expressions, but it should be able to add, subtract, multiply, divide and find square roots. Results can be approximate, showing just 3 fractional decimal digits. Thumbs up for more features like handling expressions with brackets, having a variable storing last result, converting between bases and so on.
|
||||
8. **[bytebeat](bytebeat.md)**: Make at least three cool sounding bytebeat songs.
|
||||
9. **Lorem ipsum [markdown](md.md) generator**: Create a program that generates gibberish text in markdown format that looks like normal human text. Each time it is run, it will generate generally a different text that consists of 3 to 5 sections, each section starts with a heading which starts with `# ` after which 3 to 5 words follow, then there are two newlines and then 3 to 5 paragraphs follow; each paragraph ends with two newlines, except for the last one in the document which only ends with one newline. Paragraph consists of 5 to 10 sentences; each sentence consists of 3 to 10 words, starts with capital letter (other letters are lowercase) and ends with period. About 1 in 20 words in paragraphs are highlighted -- highlight is either italic (the word is between `*`s) or bold (the word is between `**`s). After period there is space except when it's the last period in a paragraph (then there is no space). Words are selected randomly from some set of words that you define (have at least 10 different words). Thumbs up for also generating lists etc.
|
||||
10. **Caesar cipher**: Make a program that encrypts/decrypts text with the simple cipher known as Caesar cipher, i.e. by offsetting each letter by certain fixed number *N* (e.g. with *N = 2* the letter *A* will become *C*, *B* will become *D* etc.). Assume just ASCII characters on input (encrypted output can be non-ASCII). You can just choose and hardcode some specific *N* but thumbs up for allowing to set any *N*. You can input/output text from/to standard input/output or files -- it's up to you -- also you can either make one program that does both encoding and decoding (e.g. depending on CLI flag) or make two programs, one for each task.
|
||||
11. **simple website generator**: All static site generators suck ass, make your own. Make a simple markup language and a program that will turn this markup into [HTML](html.md) file -- this will allow you to write HTML websites very easily. The program will read the input file on standard input (i.e. NOT from a file, though you can optionally support this too) and output the HTML on standard output (again, output to file is optional), so that the program can be used like this: `cat myfile.mymarkup | ./mymarkupprocessor > mywebpage.html`. The markup language may be super simple: let's say `_` and `;_` could mark the start and end of bold text (translating to `<b>` and `</b>` respectively) , `#` and `;#` start and end of heading (translating to `<h1>` and `</h1>` respectively) and so on (you can make your own tags, this is just an example). Basically you'll be mostly just translating your tags into HTML tags. You don't have to implement escape sequences for special characters (i.e. it's fine if it's impossible to have let's say the `#` character in your output), but thumbs up if you do. You HAVE TO output a correct HTML, i.e. you have to output a prologue (something like `<html> <head> </head> <body> ...`) and epilogue (something like `</body> </html>`) and somehow deal with possible HTML special characters in the input text: for example if the input contains `<`, you have to translate it to `<` etc., but it is allowed to handle non-trivial cases (like weird Unicode stuff or something) by e.g. just replacing problematic input with `???`. [Unicode](unicode.md) doesn't have to be supported on output, you can output plain [ASCII](ascii.md). You have to support at least normal text, 2 levels of headings and bold text, thumbs up for additional things like images, links, lists etc. Thumbs up for additional features like allowing to set website title with a CLI flag, choose from several hardcoded [CSS](css.md) styles or adding extra output formats like [Markdown](md.md), LaTeX and so on. Test that you generate correct HTML with some HTML validator.
|
||||
12. **filetype guesser**: Create a program that reads a file and guesses its file type. You can NOT use the file name, only the file content. First look at the [magic number](magic_number.md) (file signature) -- check at least PDF, JPEG, PNG, MP3, GIF and TAR. If this doesn't succeed, then see if 90% of bytes are printable ASCII characters: if so, then guess the file to be TXT, otherwise you may report unknown type (or optionally you can try some extra checks if you want).
|
||||
13. **[brainfuck](brainfuck.md) interpreter**: Make a program that interprets brainfuck. You may choose to read the input program either from standard input or from a file (the file may have some hardcoded name, e.g. your program will just look for a file named `program.bf` in the same directory). If the brainfuck program is invalid or runtime error occurs in it, you may just write out `error` and halt your interpreter. Thumbs up for making the interpreter nicer, e.g. allowing to pass input file name as a CLI argument, reporting more details about errors (e.g. its position in source code) and so on.
|
||||
4. **[permutations](permutation.md)**: Make a program that will take as argument a single decimal digit *N* (no need to check errors). The program will then write all permutations of length *N* (each exactly once), using letters of the alphabet (e.g. passing *N = 3* may write out `abc`, `acb`, `bac`, `bca`, `cab`, `cba`, separated by newlines).
|
||||
5. **[game of life](game_of_life.md)**: Make a program that simulates game of life on a finite *N * N* grid, with wrapping space (i.e. a cell on the very left of the grid is considered a neighbor of the cell on the very right in the same row, same thing with top and bottom). Make *N* configurable at least as a compile time option, draw the world as [ASCII art](ascii_art.md) to terminal, make the user step forward by pressing some key. You can initialize the grid values randomly, but thumbs up for allowing setting the initial world state (e.g. reading it from a file or something).
|
||||
6. **[anagram](anagram.md) checker**: Make a program that reads two words and checks if they are an anagram of each other or not (i.e. one can be made from the other just by rearranging the letters). You can just output *yes* or *no*.
|
||||
7. **text adventure**: Make an interactive [CLI](cli.md) text adventure that will take an average player at least 10 minutes to finish. Part of game mechanics must involve inventory, i.e. picking up items, carrying them around and using them.
|
||||
8. **calculator**: Make an interactive calculator -- it can be a purely [command line](cli.md) program into which user types expressions and your program evaluates them. The functionality must be at least on the level of the most plain physical calculators, i.e. it doesn't have to parse whole complex expressions, but it should be able to add, subtract, multiply, divide and find square roots. Results can be approximate, showing just 3 fractional decimal digits. Thumbs up for more features like handling expressions with brackets, having a variable storing last result, converting between bases and so on.
|
||||
9. **[bytebeat](bytebeat.md)**: Make at least three cool sounding bytebeat songs.
|
||||
10. **Lorem ipsum [markdown](md.md) generator**: Create a program that generates gibberish text in markdown format that looks like normal human text. Each time it is run, it will generate generally a different text that consists of 3 to 5 sections, each section starts with a heading which starts with `# ` after which 3 to 5 words follow, then there are two newlines and then 3 to 5 paragraphs follow; each paragraph ends with two newlines, except for the last one in the document which only ends with one newline. Paragraph consists of 5 to 10 sentences; each sentence consists of 3 to 10 words, starts with capital letter (other letters are lowercase) and ends with period. About 1 in 20 words in paragraphs are highlighted -- highlight is either italic (the word is between `*`s) or bold (the word is between `**`s). After period there is space except when it's the last period in a paragraph (then there is no space). Words are selected randomly from some set of words that you define (have at least 10 different words). Thumbs up for also generating lists etc.
|
||||
11. **Caesar cipher**: Make a program that encrypts/decrypts text with the simple cipher known as Caesar cipher, i.e. by offsetting each letter by certain fixed number *N* (e.g. with *N = 2* the letter *A* will become *C*, *B* will become *D* etc.). Assume just ASCII characters on input (encrypted output can be non-ASCII). You can just choose and hardcode some specific *N* but thumbs up for allowing to set any *N*. You can input/output text from/to standard input/output or files -- it's up to you -- also you can either make one program that does both encoding and decoding (e.g. depending on CLI flag) or make two programs, one for each task.
|
||||
12. **simple website generator**: All static site generators suck ass, make your own. Make a simple markup language and a program that will turn this markup into [HTML](html.md) file -- this will allow you to write HTML websites very easily. The program will read the input file on standard input (i.e. NOT from a file, though you can optionally support this too) and output the HTML on standard output (again, output to file is optional), so that the program can be used like this: `cat myfile.mymarkup | ./mymarkupprocessor > mywebpage.html`. The markup language may be super simple: let's say `_` and `;_` could mark the start and end of bold text (translating to `<b>` and `</b>` respectively) , `#` and `;#` start and end of heading (translating to `<h1>` and `</h1>` respectively) and so on (you can make your own tags, this is just an example). Basically you'll be mostly just translating your tags into HTML tags. You don't have to implement escape sequences for special characters (i.e. it's fine if it's impossible to have let's say the `#` character in your output), but thumbs up if you do. You HAVE TO output a correct HTML, i.e. you have to output a prologue (something like `<html> <head> </head> <body> ...`) and epilogue (something like `</body> </html>`) and somehow deal with possible HTML special characters in the input text: for example if the input contains `<`, you have to translate it to `<` etc., but it is allowed to handle non-trivial cases (like weird Unicode stuff or something) by e.g. just replacing problematic input with `???`. [Unicode](unicode.md) doesn't have to be supported on output, you can output plain [ASCII](ascii.md). You have to support at least normal text, 2 levels of headings and bold text, thumbs up for additional things like images, links, lists etc. Thumbs up for additional features like allowing to set website title with a CLI flag, choose from several hardcoded [CSS](css.md) styles or adding extra output formats like [Markdown](md.md), LaTeX and so on. Test that you generate correct HTML with some HTML validator.
|
||||
13. **filetype guesser**: Create a program that reads a file and guesses its file type. You can NOT use the file name, only the file content. First look at the [magic number](magic_number.md) (file signature) -- check at least PDF, JPEG, PNG, MP3, GIF and TAR. If this doesn't succeed, then see if 90% of bytes are printable ASCII characters: if so, then guess the file to be TXT, otherwise you may report unknown type (or optionally you can try some extra checks if you want).
|
||||
14. **[brainfuck](brainfuck.md) interpreter**: Make a program that interprets brainfuck. You may choose to read the input program either from standard input or from a file (the file may have some hardcoded name, e.g. your program will just look for a file named `program.bf` in the same directory). If the brainfuck program is invalid or runtime error occurs in it, you may just write out `error` and halt your interpreter. Thumbs up for making the interpreter nicer, e.g. allowing to pass input file name as a CLI argument, reporting more details about errors (e.g. its position in source code) and so on.
|
||||
|
||||
### Level 2: Mid, *Hurt Me Plenty*
|
||||
|
||||
|
@ -227,8 +229,9 @@ Bear in mind this is not a school test that's supposed to decide if you get to a
|
|||
120. We have a rubber rope 1 meter long. On one side there is an ant. He starts moving over the rubber towards its other end by the speed of 1 cm/s, however as he starts to move we start stretching the rubber also by the speed of 1 cm/s, so that after 1 second it's 101 cm long, after 2 seconds it's 102 cm long etc. The ant keeps the same speed. Will he ever reach the end? How long would it take him?
|
||||
121. Today in [slavery](work.md) I tried to fix 6 computers: I ended up destroying twice as many of them than I fixed. Every time I destroyed a computer my boss told me I'm a retard. How many times did my boss repeat I'm a retard?
|
||||
122. What does constant [bitrate](bitrate.md) mean in relation to video encoding? What are some of its advantages and disadvantages against variable bitrate?
|
||||
123. Write the hexadecimal values of a pure green color in 24 bit RGB, [RGB565](rgb565.md) and [RGB332](rgb332.md) formats.
|
||||
124. Did you enjoy this quiz?
|
||||
123. The ISS orbits 400 km above [Earth](earth.md) surface. The Earth radius is 6378 km. How far away (from the ISS) is the Earth's horizon?
|
||||
124. Write the hexadecimal values of a pure green color in 24 bit RGB, [RGB565](rgb565.md) and [RGB332](rgb332.md) formats.
|
||||
125. Did you enjoy this quiz?
|
||||
|
||||
### Answers
|
||||
|
||||
|
@ -355,8 +358,9 @@ sin(x) / cos(x) - log2(2) = tg(x) - 1*, so we get *tg(x) >= 1*. So that will hol
|
|||
120. Let *p* be the ant's relative position on the rubber, i.e. the fraction of the rubber he has already traveled; when *p = 1* he'll be in the finish. At the beginning his speed in fractions of the rubber per second is *v = 1/100*. As the rubber expands, the fractional speed decreases (he keeps moving at 1 cm/s but the total number of cm to be traveled increases): we can write the speed as a function of time: *v = 1/(100 + t)*. Now the fractional position *p* over time is an [integral](integral.md) of speed, i.e. *p = integrate 1/(100 + t) dt = log(100 + t) + C* and the initial position is *p = 0*, i.e. *C = -log(100)*, so *p = log(100 + t) - log(100)*. Now we just have to compute when *p* reaches 1, i.e. *log(100 + t) - log(100) = 1*, which gives us *t = 100 * (e - 1) ~= 171.83*. So the ant will reach the end in nearly 3 minutes.
|
||||
121. 3: I destroyed 4 computers, so he told me 4 times I'm a retard, i.e. he first told me I'm a retard (this was not a repetition) and then repeated it three times.
|
||||
122. Constant bitrate means a given time unit of the video will always be encoded with (at least approximately) the same number of [bits](bit.md). One second of the video will therefore take the same size no matter how complex or simple the encoded scene is. Advantages are for example being able to estimate size of any video just from its duration alone, easier seeking and rewinding to a random position, or that during streaming over network there will be a constant number of bits transferred per second, which is very predictable and good for many protocols. Disadvantage may be that sometimes space is wasted (we encode a simple scene with more bits than necessary) and that quality of the video won't be constant (scenes for which bits don't suffice will have to have their quality lowered).
|
||||
123. 24 bit RGB is easy: 00ff00. For 565 we want a 16 bit value whose upper and lower 5 bits are zero, with the middle bits being ones, i.e. 0000011111100000 in binary, which is 07e0 in hexadecimal. Similarly for 332 we get 1c.
|
||||
124. yes
|
||||
123. Draw the shit on paper: draw a ball (Earth) and a point above it (ISS), then draw a tangent line from the point to the ball. Then draw a line from the ball center to the ISS and from the ball center to where the tangent line touches that ball (the horizon). Obviously there's a right angle at the tangent line touch point, so we have a right triangle. One side is the Earth radius and the longest side is the radius plus the orbit height. From this we compute the remaining side as *sqrt((6378 + 400)^2 - 6378^2)*, which gives us approx. 2293 km.
|
||||
124. 24 bit RGB is easy: 00ff00. For 565 we want a 16 bit value whose upper and lower 5 bits are zero, with the middle bits being ones, i.e. 0000011111100000 in binary, which is 07e0 in hexadecimal. Similarly for 332 we get 1c.
|
||||
125. yes
|
||||
|
||||
## Other
|
||||
|
||||
|
|
|
@ -54,17 +54,17 @@ Let's demonstrate it on a few examples:
|
|||
|
||||
## History
|
||||
|
||||
Precursors to free software may reach as far back in [history](history.md) as we are willing look. They may include for example ancient [mathematicians](math.md) sharing their equations with each other, people sharing recipes for meals and possibly even the general ideas of [communism](communism.md) (not to be [confused](often_confused.md) with [Marxism](marxism.md)). Early digital sharing communities on networks such as [BBS](bbs.md) and [Usenet](usenet.md) worked like free software communities "by default", without really articulating or naming the concept -- they shared software informally without [licenses](license.md) as back then capitalists haven't yet had enough time to ruin everything, but that slowly started to change with more commercialization of the brand new field.
|
||||
Precursors to free software may reach as far back in [history](history.md) as we are willing to look. They may include for example ancient [mathematicians](math.md) sharing their equations with each other, engineers sharing plans, people sharing recipes for meals, and influence can possibly also come from the general ideas of [communism](communism.md) (not to be [confused](often_confused.md) with [Marxism](marxism.md)). In 20th century the early digital sharing communities on networks such as [BBS](bbs.md) and [Usenet](usenet.md) worked like free software communities "by default", without really articulating or naming the concept -- they shared software informally without [licenses](license.md) as back then it was believed [copyright](copyright.md) didn't even apply to software -- capitalists haven't yet had enough time to fuck everything up, but that slowly started to change with more commercialization of the brand new field and legal cases that would indeed establish that software was copyrightable.
|
||||
|
||||
Free software, in a form discussed here, was invented by [Richard Stallman](rms.md) in the 1980s. He cites his frustration with a proprietary printer driver as an initial impulse. In 1983 he announced the now already legendary project called [GNU](gnu.md) -- one to implement a completely free as in freedom [operating system](os.md). The announcement already contains the word "free", but more in a sense of "not having to pay for permissions". Additionally in 1985 Stallman established the [Free Software Foundation](fsf.md), a non-profit for promotion and support of free software, and this is when the term *free software* seems to have been clearly distinguished.
|
||||
Free software, in a form discussed here, was invented by [Richard Stallman](rms.md) in the 1980s. He cites his frustration with a proprietary printer driver as an initial impulse. In 1983 he announced the now already legendary project called [GNU](gnu.md) -- one to implement a completely free as in freedom [operating system](os.md). The announcement described the system as "free", however still more in a sense of "not having to pay for permissions". Additionally in 1985 Stallman established the [Free Software Foundation](fsf.md), a non-profit for promotion and support of free software, and this is when the term *free software* seems to have been clearly distinguished. In late 1980s Stallman wrote [GPL](gpl.md), the major (and now one of the most frequent) free licenses. Other standard free licenses, such as the [MIT](mit.md) or [BSD](bsd.md), also appeared around this time. Before these standard licenses programs had to use custom ones, which was much harder and less legally safe.
|
||||
|
||||
In early [1990s](90s.md) a new project called [Linux](linux.md) -- an operating system kernel -- joined GNU and as a final piece of the puzzle completed its main goal. From now on it became practically possibly to do one's computing solely with free software.
|
||||
|
||||
Free software gained enough momentum to become a serious threat to capitalism and many started to attack it, most notably [Microsoft](microsoft.md) who was caught red handed with the leak of so called *Halloween documents* in late [1990s](90s.md), in which they discuss strategies for eliminating the threat of free software.
|
||||
Free software gained enough momentum to become a serious threat to capitalism and so opposition appeared, most notably [Microsoft](microsoft.md), caught red handed with the leak of so called *Halloween documents* in late [1990s](90s.md), in which they discuss strategies for eliminating the threat of free software. Despite this free software couldn't be stopped and grew in popularity, which is apparent from the huge success of [GNU](gnu.md)/[Linux](linux.md) and from the cases when very valuable software, such as the [Doom](doom.md) engine or [Blender](blender.md), got released under free terms.
|
||||
|
||||
Later on the free software movement inspired movements such as [free culture](free_culture.md) (shortly after the year 2000) and the evil [open-source](open_source.md) [fork](fork.md) (1998, a malicious response of business, a kind of "free software" minus ethics).
|
||||
Later on free software inspired movements such as [free culture](free_culture.md) (shortly after the year 2000) and the evil [open-source](open_source.md) [fork](fork.md) (1998, a malicious response of business, a kind of "free software" minus ethics).
|
||||
|
||||
TODO: more more more, famous cases of FS (Doom engine, ...)
|
||||
Sadly around 2010 (aka the year when everything started to go to [shit](shit.md)) the "open source" wave was already overshadowing free software. This was really a part of the great societal [downfall](collapse.md), the time when dystopian ultracapitalism finally got to finishing off the last remnants of ethical values in society.
|
||||
|
||||
**By 2024 free software is dead** -- yes, [FSF](fsf.md) and a few other software "activists" are still around, but they don't bear any significance anymore, the free software movement disappeared just like hippies disappeared with 1960s. FSF has become just an email spamming organization supporting lesbian [rights](rights_culture.md) on the Internet, and those who truly believe in free software form a community that by its size is comparable to such insignificantly small groups as [suckless](suckless.md) for example. Everything is now "[open $ource](open_source.md)", which only means one thing: it is hosted on [GitHub](github.md), and doesn't at all imply free code, available code, non-malicious features or even perhaps such a laughable thing as pursuit of freedom. Corruption, politics and [free market](capitalism.md) have finally killed the free software movement, [open $ource](open_source.md) prevailed exactly as it was planned by capitalists at the meeting in 1998, and it has now redefined even the basic pillars of the four freedoms (partial openness, [fair use](fair_use.md) or just source availability is now practically synonymous with "open source") -- just like for example "thou shalt not kill" was removed from Christianity because it wasn't convenient for the overlords -- and by this the fate of technology is sealed, free software seems to have only postponed the [capitalist disaster](capitalist_singularity.md) by a few decades, which is still a remarkable feat. { It's been pointed out to me that even some project that call themselves "free" or "libre", such as "Libre"Boot, are in fact breaking the rules of freedom now, for example by including proprietary blobs. ~drummyfish }
|
||||
|
||||
|
|
3702
random_page.md
3702
random_page.md
File diff suppressed because it is too large
Load diff
|
@ -1,10 +1,12 @@
|
|||
# Shader
|
||||
|
||||
Shader is a computer [program](program.md) running on the [graphics processing unit](gpu.md) (GPU), typically in many parallel instances so as to utilize the GPU's highly parallel nature and so achieve very high processing speed. As such shaders are simple to mid complexity programs. There are different types of shaders based on what kind of data they process -- most notable are probably fragment (also pixel) shaders that process [pixels](pixel.md) which then end up on the screen -- without explicitly mentioning what kind of shader we are talking about it is usually assumed we mean fragment shaders. The word *shader* is also used more loosely as a synonym for a special visual effect or material look in [3D graphics](3d_rendering.md) (e.g. [games](games.md)), because shaders are usually the means of achieving such effects.
|
||||
Shader is a [computer](computer.md) [program](program.md) running on the [graphics processing unit](gpu.md) (GPU), typically in many parallel instances so as to utilize the GPU's highly parallel nature and so achieve very high processing speed. As such shaders are simple to mid complexity programs. There are different types of shaders based on what kind of [data](data.md) they process -- most notable are probably fragment (also pixel) shaders that process [pixels](pixel.md) which then end up on the screen -- without explicitly mentioning what kind of shader we are talking about it is usually assumed we mean fragment shaders. The word *shader* is also used more loosely as a synonym for a special visual effect or material look in [3D graphics](3d_rendering.md) (e.g. [games](games.md)), because shaders are usually the means of achieving such effects.
|
||||
|
||||
Why is it called a *shader*? Well, probably because these programs were initially very limited and only intended for implementation of shading (i.e. slight brightening/darkening of the surface color to simulate the effects of light), so the name was logical. It stuck and remained even as the power and flexibility of shaders increased to allow doing much more, and this even affected the word *shading* whose meaning is now sometimes extended to include practically any effect applied on the object surface.
|
||||
|
||||
Shaders are normally written in a special **shading language** such as [GLSL](glsl.md) in the [OpenGL](opengl.md) [API](api.md), [HLSL](hlsl.md) ([proprietary](proprietary.md)) in [Direct3D](d3d.md) API or the Metal shading language ([proprietary](proprietary.md)) in [Metal](metal.md) API. These languages are often similar to [C](c.md) with some additions (e.g. vector and matrix data types) and simplifications (e.g. no function [recursion](recursion.md) or dynamic memory allocation). High level [frameworks](framework.md) like [Blender](blender.md) many times offer [visual programming](visual_programming.md) (point-n-click) of shaders with graph/node editors.
|
||||
|
||||
Initially (basically early 2000s) shaders were used only for graphics, i.e. to transform 3D vertices, draw triangles and compute pixel colors. Later on as GPUs became more general purpose ([GPGPU](gpgpu.md)), flexibility was added to shaders that allowed to solve more problems with the GPU and eventually general *compute* shaders appeared (OpenGL added them in version 3.3 in 2010).
|
||||
Initially (basically early [2000s](2000s.md)) shaders were used only for graphics, i.e. to transform 3D vertices, draw triangles and compute pixel colors. Later on as GPUs became more general purpose ([GPGPU](gpgpu.md)), flexibility was added to shaders that allowed to solve more problems with the GPU and eventually general *compute* shaders appeared (OpenGL added them in version 3.3 in 2010).
|
||||
|
||||
To put shaders in the context, the flow of data is this: a [CPU](cpu.md) uploads some data (3D models, textures, ...) to the GPU and then issues a draw command -- this makes the GPU start its **[pipeline](pipeline.md)** consisting of different **stages**, e.g. the vertices of 3D models are transformed to screens space (the vertex stage), then triangles are generated and rasterized (the shading stage) and the data is output (on screen, to a buffer etc.). Some of these stages are programmable and so they have their own type of a shader. The details of the pipeline differ from API to API, but in general, depending on the type of data the shader processes (the stage), we talk about:
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
112
wiki_stats.md
112
wiki_stats.md
|
@ -3,9 +3,9 @@
|
|||
This is an autogenerated article holding stats about this wiki.
|
||||
|
||||
- number of articles: 626
|
||||
- number of commits: 980
|
||||
- total size of all texts in bytes: 5118393
|
||||
- total number of lines of article texts: 37142
|
||||
- number of commits: 981
|
||||
- total size of all texts in bytes: 5126895
|
||||
- total number of lines of article texts: 37184
|
||||
- number of script lines: 324
|
||||
- occurrences of the word "person": 10
|
||||
- occurrences of the word "nigger": 114
|
||||
|
@ -27,68 +27,83 @@ longest articles:
|
|||
- [3d_model](3d_model.md): 44K
|
||||
- [internet](internet.md): 44K
|
||||
- [main](main.md): 40K
|
||||
- [iq](iq.md): 40K
|
||||
- [bloat](bloat.md): 40K
|
||||
- [iq](iq.md): 40K
|
||||
- [copyright](copyright.md): 40K
|
||||
- [cheating](cheating.md): 36K
|
||||
- [raycasting](raycasting.md): 36K
|
||||
|
||||
top 50 5+ letter words:
|
||||
|
||||
- which (2823)
|
||||
- there (2214)
|
||||
- people (2174)
|
||||
- example (1786)
|
||||
- other (1597)
|
||||
- about (1422)
|
||||
- number (1333)
|
||||
- software (1267)
|
||||
- because (1175)
|
||||
- their (1104)
|
||||
- would (1073)
|
||||
- which (2826)
|
||||
- there (2216)
|
||||
- people (2176)
|
||||
- example (1792)
|
||||
- other (1602)
|
||||
- about (1424)
|
||||
- number (1334)
|
||||
- software (1280)
|
||||
- because (1176)
|
||||
- their (1105)
|
||||
- would (1074)
|
||||
- something (1056)
|
||||
- program (1052)
|
||||
- being (1033)
|
||||
- program (1056)
|
||||
- being (1034)
|
||||
- things (962)
|
||||
- called (942)
|
||||
- language (938)
|
||||
- called (936)
|
||||
- without (865)
|
||||
- without (867)
|
||||
- function (864)
|
||||
- simple (863)
|
||||
- computer (844)
|
||||
- numbers (834)
|
||||
- different (797)
|
||||
- these (784)
|
||||
- however (780)
|
||||
- different (798)
|
||||
- these (785)
|
||||
- however (781)
|
||||
- programming (771)
|
||||
- world (760)
|
||||
- system (743)
|
||||
- should (723)
|
||||
- doesn (715)
|
||||
- system (746)
|
||||
- should (725)
|
||||
- doesn (716)
|
||||
- still (712)
|
||||
- games (692)
|
||||
- while (673)
|
||||
- games (693)
|
||||
- while (674)
|
||||
- drummyfish (673)
|
||||
- society (672)
|
||||
- drummyfish (671)
|
||||
- point (669)
|
||||
- simply (656)
|
||||
- possible (655)
|
||||
- probably (646)
|
||||
- probably (648)
|
||||
- using (644)
|
||||
- always (633)
|
||||
- course (612)
|
||||
- similar (602)
|
||||
- actually (592)
|
||||
- someone (587)
|
||||
- always (634)
|
||||
- course (611)
|
||||
- similar (605)
|
||||
- actually (594)
|
||||
- someone (588)
|
||||
- https (587)
|
||||
- though (582)
|
||||
- basically (572)
|
||||
- really (569)
|
||||
- usually (556)
|
||||
- really (570)
|
||||
- first (556)
|
||||
|
||||
latest changes:
|
||||
|
||||
```
|
||||
Date: Tue Mar 4 21:04:02 2025 +0100
|
||||
bloat.md
|
||||
c.md
|
||||
cyber.md
|
||||
deferred_shading.md
|
||||
entrepreneur.md
|
||||
exercises.md
|
||||
free_software.md
|
||||
gnu.md
|
||||
political_correctness.md
|
||||
project.md
|
||||
random_page.md
|
||||
unix.md
|
||||
wiki_pages.md
|
||||
wiki_stats.md
|
||||
Date: Sun Mar 2 21:01:56 2025 +0100
|
||||
ascii.md
|
||||
atheism.md
|
||||
|
@ -107,21 +122,6 @@ Date: Sat Mar 1 19:31:47 2025 +0100
|
|||
compression.md
|
||||
faq.md
|
||||
go.md
|
||||
how_to.md
|
||||
jokes.md
|
||||
number.md
|
||||
political_correctness.md
|
||||
random_page.md
|
||||
stereotype.md
|
||||
unix.md
|
||||
wiki_pages.md
|
||||
wiki_stats.md
|
||||
Date: Sat Mar 1 13:35:54 2025 +0100
|
||||
compression.md
|
||||
free_culture.md
|
||||
free_software.md
|
||||
fsf.md
|
||||
gnu.md
|
||||
```
|
||||
|
||||
most wanted pages:
|
||||
|
@ -152,7 +152,7 @@ most popular and lonely pages:
|
|||
- [lrs](lrs.md) (337)
|
||||
- [capitalism](capitalism.md) (305)
|
||||
- [c](c.md) (239)
|
||||
- [bloat](bloat.md) (230)
|
||||
- [bloat](bloat.md) (231)
|
||||
- [free_software](free_software.md) (198)
|
||||
- [game](game.md) (152)
|
||||
- [suckless](suckless.md) (149)
|
||||
|
@ -162,12 +162,12 @@ most popular and lonely pages:
|
|||
- [censorship](censorship.md) (116)
|
||||
- [computer](computer.md) (113)
|
||||
- [kiss](kiss.md) (111)
|
||||
- [programming](programming.md) (108)
|
||||
- [programming](programming.md) (109)
|
||||
- [math](math.md) (105)
|
||||
- [fun](fun.md) (105)
|
||||
- [math](math.md) (104)
|
||||
- [gnu](gnu.md) (102)
|
||||
- [linux](linux.md) (103)
|
||||
- [gnu](gnu.md) (103)
|
||||
- [shit](shit.md) (101)
|
||||
- [linux](linux.md) (100)
|
||||
- [woman](woman.md) (99)
|
||||
- [corporation](corporation.md) (96)
|
||||
- [bullshit](bullshit.md) (96)
|
||||
|
|
Loading…
Reference in a new issue