text:
Oberon/V2/Draw

MODULE Draw; (*NW 29.6.88 / 22.11.91*) IMPORT Files, Fonts, Viewers, Printer, Texts, Oberon, TextFrames, MenuViewers, Graphics, GraphicFrames; VAR W: Texts.Writer; (*Exported commands: 		Open, Delete, 		SetWidth, ChangeColor, ChangeWidth, ChangeFont, 		Store, Print 		Macro, OpenMacro, MakeMacro, LoadLibrary, StoreLibrary*) PROCEDURE Open*; VAR X, Y: INTEGER; beg, end, t: LONGINT; G: Graphics.Graph; V: Viewers.Viewer; text: Texts.Text; S: Texts.Scanner; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF (S.class = Texts.Char) & (S.c = "^") THEN Oberon.GetSelection(text, beg, end, t); IF t >= 0 THEN Texts.OpenScanner(S, text, beg); Texts.Scan(S) END END ; IF S.class = Texts.Name THEN NEW(G); Graphics.Open(G, S.s); Oberon.AllocateUserViewer(Oberon.Par.vwr.X, X, Y); V := MenuViewers.New( 				TextFrames.NewMenu(S.s, 					"System.Close System.Copy System.Grow Draw.Delete Draw.Store"), 				GraphicFrames.New(G, 0, 0, 0, TRUE), TextFrames.menuH, X, Y) 		END END Open; PROCEDURE Delete*; VAR F: GraphicFrames.Frame; BEGIN IF Oberon.Par.frame = Oberon.Par.vwr.dsc THEN F := Oberon.Par.vwr.dsc.next(GraphicFrames.Frame); GraphicFrames.Erase(F); Graphics.Delete(F.graph) END END Delete; PROCEDURE SetWidth*; VAR S: Texts.Scanner; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF (S.class = Texts.Int) & (S.i > 0) & (S.i < 7) THEN Graphics.width := SHORT(S.i) END END SetWidth; PROCEDURE ChangeColor*; VAR ch: CHAR; CM: Graphics.ColorMsg; S: Texts.Scanner; BEGIN IF Oberon.Par.frame(TextFrames.Frame).sel > 0 THEN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.frame(TextFrames.Frame).selbeg.pos); Texts.Read(S, ch); CM.col := S.col ELSE Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Int THEN CM.col := SHORT(S.i) ELSE CM.col := S.col END END ; GraphicFrames.Change(GraphicFrames.Selected, CM) END ChangeColor; PROCEDURE ChangeWidth*; VAR WM: Graphics.WidMsg; S: Texts.Scanner; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Int THEN WM.w := SHORT(S.i); GraphicFrames.Change(GraphicFrames.Selected, WM) END END ChangeWidth; PROCEDURE ChangeFont*; VAR FM: Graphics.FontMsg; S: Texts.Scanner; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN FM.fnt := Fonts.This(S.s); IF FM.fnt # NIL THEN GraphicFrames.Change(GraphicFrames.Selected, FM) END END END ChangeFont; PROCEDURE Backup (VAR name: ARRAY OF CHAR); VAR res, i: INTEGER; ch: CHAR; bak: ARRAY 32 OF CHAR; BEGIN i := 0; ch := name[0]; WHILE ch > 0X DO bak[i] := ch; INC(i); ch := name[i] END ; IF i < 28 THEN bak[i] := "."; bak[i+1] := "B"; bak[i+2] := "a"; bak[i+3] := "k"; bak[i+4] := 0X; Files.Rename(name, bak, res) END END Backup; PROCEDURE Store*; VAR par: Oberon.ParList; S: Texts.Scanner; Menu: TextFrames.Frame; G: GraphicFrames.Frame; v: Viewers.Viewer; BEGIN par := Oberon.Par; IF par.frame = par.vwr. dsc THEN Menu := par.vwr.dsc(TextFrames.Frame); G := Menu.next(GraphicFrames.Frame); Texts.OpenScanner(S, Menu.text, 0); Texts.Scan(S); IF S.class = Texts.Name THEN Texts.WriteString(W, S.s); Texts.WriteString(W, " storing"); Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf); Backup(S.s); Graphics.WriteFile(G.graph, S.s) 			END ELSE Texts.OpenScanner(S, par.text, par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN v := Oberon.MarkedViewer; IF (v.dsc # NIL) & (v.dsc.next IS GraphicFrames.Frame) THEN G := v.dsc.next(GraphicFrames.Frame); Texts.WriteString(W, S.s); Texts.WriteString(W, " storing"); Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf); Backup(S.s); Graphics.WriteFile(G.graph, S.s) 				END END END END Store; PROCEDURE Print*; VAR nofcopies: INTEGER; S: Texts.Scanner; G: Graphics.Graph; V: Viewers.Viewer; PROCEDURE Copies; VAR ch: CHAR; BEGIN nofcopies := 1; IF S.nextCh = "/" THEN Texts.Read(S, ch); IF (ch >= "0") & (ch <= "9") THEN nofcopies := ORD(ch) - 30H END ; WHILE ch > " " DO Texts.Read(S, ch) END ; S.nextCh := ch 			END END Copies; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN Printer.Open(S.s, Oberon.User, Oberon.Password); IF Printer.res = 0 THEN Texts.Scan(S); WHILE S.class = Texts.Name DO 					Texts.WriteString(W, S.s); Copies; Graphics.Open(G, S.s); IF Graphics.res = 0 THEN Texts.WriteString(W, " printing"); Texts.WriteInt(W, nofcopies, 3); Texts.Append(Oberon.Log, W.buf); Graphics.Print(G, 0, Printer.PageHeight-128); Printer.Page(nofcopies) ELSE Texts.WriteString(W, " not found") END ; Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf); Texts.Scan(S) END ; IF (S.class = Texts.Char) & (S.c = "*") THEN Copies; V := Oberon.MarkedViewer; IF (V.dsc # NIL) & (V.dsc.next IS GraphicFrames.Frame) THEN Texts.OpenScanner(S, V.dsc(TextFrames.Frame).text, 0); Texts.Scan(S); IF S.class = Texts.Name THEN Texts.WriteString(W, S.s); Texts.WriteString(W, " printing"); Texts.WriteInt(W, nofcopies, 3); Texts.Append(Oberon.Log, W.buf); Graphics.Print(V.dsc.next(GraphicFrames.Frame).graph, 0, Printer.PageHeight-128); Printer.Page(nofcopies) END END END ; Printer.Close ELSIF Printer.res = 1 THEN Texts.WriteString(W, " no printer") ELSIF Printer.res = 2 THEN Texts.WriteString(W, " no link") ELSIF Printer.res = 3 THEN Texts.WriteString(W, " bad response") ELSIF Printer.res = 4 THEN Texts.WriteString(W, " no permission") END END ; Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf) END Print; PROCEDURE Macro*; VAR S: Texts.Scanner; T: Texts.Text; time, beg, end: LONGINT; Lname: ARRAY 32 OF CHAR; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN COPY(S.s, Lname); Texts.Scan(S); IF (S.class = Texts.Char) & (S.c = "^") THEN Oberon.GetSelection(T, beg, end, time); IF time >= 0 THEN Texts.OpenScanner(S, T, beg); Texts.Scan(S) END END ; IF (S.class = Texts.Name) OR (S.class = Texts.String) THEN GraphicFrames.Macro(Lname, S.s) 			END END END Macro; PROCEDURE OpenMacro*; VAR F: GraphicFrames.Frame; sel: Graphics.Object; BEGIN F := GraphicFrames.Selected; IF F # NIL THEN sel := F.graph.sel; IF (sel # NIL) & (sel IS Graphics.Macro) THEN GraphicFrames.Deselect(F); Graphics.OpenMac(sel(Graphics.Macro).mac, F.graph, F.mark.x - F.x, F.mark.y - F.y); GraphicFrames.Draw(F) END END END OpenMacro; PROCEDURE MakeMacro*; VAR new: BOOLEAN; F: GraphicFrames.Frame; S: Texts.Scanner; Lname: ARRAY 32 OF CHAR; PROCEDURE MakeMac; VAR x0, y0, x1, y1, w, h: INTEGER; mh: Graphics.MacHead; L: Graphics.Library; BEGIN L := Graphics.ThisLib(Lname, FALSE); IF L = NIL THEN L := Graphics.NewLib(Lname) END ; x0 := F.mark.x; y0 := F.mark.y; x1 := F.mark.next.x; y1 := F.mark.next.y; 			w := ABS(x1-x0); h := ABS(y1-y0); IF x0 < x1 THEN x0 := x0 - F.x ELSE x0 := x1 - F.x END ; IF y0 < y1 THEN y0 := y0 - F.y ELSE y0 := y1 - F.y END ; mh := Graphics.MakeMac(F.graph, x0, y0, w, h, S.s); Graphics.InsertMac(mh, L, new) END MakeMac; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN COPY(S.s, Lname); Texts.Scan(S); IF (S.class = Texts.Name) OR (S.class = Texts.String) & (S.len <= 8) THEN F := GraphicFrames.Focus; IF (F # NIL) & (F.graph.sel # NIL) THEN MakeMac; Texts.WriteString(W, S.s); IF new THEN Texts.WriteString(W, " inserted in ") ELSE Texts.WriteString(W, " replaced in ") END ; Texts.WriteString(W, Lname); Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf) END END END END MakeMacro; PROCEDURE LoadLibrary*; VAR S: Texts.Scanner; L: Graphics.Library; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN L := Graphics.ThisLib(S.s, TRUE); Texts.WriteString(W, S.s); Texts.WriteString(W, " loaded"); Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf) END END LoadLibrary; PROCEDURE StoreLibrary*; VAR i: INTEGER; S: Texts.Scanner; L: Graphics.Library; Lname: ARRAY 32 OF CHAR; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Name THEN i := 0; WHILE S.s[i] >= "0" DO Lname[i] := S.s[i]; INC(i) END ; Lname[i] := 0X; L := Graphics.ThisLib(Lname, FALSE); IF L # NIL THEN Texts.WriteString(W, S.s); Texts.WriteString(W, " storing"); Texts.WriteLn(W); Texts.Append(Oberon.Log, W.buf); Graphics.StoreLib(L, S.s) 			END END END StoreLibrary; BEGIN Texts.OpenWriter(W) END Draw.

title: Oberon/V2/Draw


text:
User talk:Gillespk

Welcome!
Welcome to Wikibooks, Gillespk!

 First steps tutorial Wikibooks is for collaborative development of free textbooks.

You do not need technical skills to contribute. You can easily change most books. Please introduce yourself, and let us know what interests you.

If you already contribute at other Wikimedia projects, our Wikimedia Orientation should quickly get you started. (Would you like to provide feedback on this message?)

  Getting help   Made a mistake?   Goodies, tips and tricks
 * Read the Using Wikibooks book for a friendly introduction to the project, or our help pages for more information.
 * You can get friendly help from the community in the user assistance room or our IRC channel.
 * Upload freely licensed files to Wikimedia Commons. You may request permission to upload fair use files locally. Please include author and source information and a non-free use rationale for non-free files.
 * You can restore a previously saved version.
 * Pages should follow the  naming convention.
 * Need to rename a page? Use the move tab (is available once your account is 4 days old - until then, ask for help).
 * To request a page be deleted, add to the top of the page.
 * Was a page you made deleted? Please read the deletion policy, and check the deletion log to find out why. Also check the RFD archives if applicable. You can request undeletion at WB:RFU, or ask the administrator who deleted the page.
 * Please fill in the edit summary and preview your edits before saving.
 * Sign your name on discussion pages by typing ~~~~
 * User scripts can make many tasks easier. Look at the Gadgets tab of my preferences; check off the boxes for the scripts you want, and hit save!

-- Jules (Mrjulesd) 20:54, 28 February 2021 (UTC)

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

title: User talk:Gillespk


text: Template:Ucr

title: Template:Ucr


text:
Talk:Engineering Acoustics/Reflection and transmission of planar waves

I believe the derivative of u = u_0 * exp(j*(ω*t-k*x)) is: j*ω *u


text:
German/Grammar/Polar questions

Polar questions
Simple statements are fine, but sometimes you just need to ask, so this section will cover a simple type of question.

Terminology
German is often classified as a V2 language because of the V2 word order discussed earlier. This is not strictly true though because many sentences, and clauses within sentences, follow a different pattern. Depending on the type of sentence or clause, it might have V1 (verb first), VL (verb last), or V0 (no finite verb at all) word order. Although the V2 order is used in the most common type of sentence, a declarative statement, the other orders are frequently used and it's better to think of them as a way to categorize sentence types.

A polar question, also called a yes-no question, or perhaps in German a ja-nein question, is a question which simply askes if the corresponding statement is true. An example in English is "Are you working?" The name yes-no question question comes from the fact that "Yes," and "No," are acceptable answers. This type of question follows the V1 word order as we shall see.

Forming polar questions
In German, you can form a polar question from a statement by moving the verb from its V2 position to the beginning, the V1 position. For example: becomes This is similar to the way such questions are formed in English, except, as with negation, German does not require an extra verb ("do" or "be") as English does.
 * Du arbeitest. ― "You are working."
 * Arbeitest du? ― "Are you working?"

You can, of course, include adverbs to make your questions more interesting. For example: becomes
 * Du schläfst hier. ― "You sleep here."
 * Schläfst du hier? ― "Do you sleep here?"

And becomes
 * Sie kochen gern. ― "You like to cook."
 * Kochen Sie gern? ― "Do you like to cook?"

Verbs and subjects like to stay near each other so you would normally put the subject right after the verb, making the word order less flexible in this type of question.

The adverb nicht can be used to slant your question in a particular way, so: becomes
 * Du hörst nicht. ― "You don't hear."
 * Hörst du nicht? ― "Don't you hear?"

Acceptable answers
Knowing how to ask a question is only useful if you can understand the answer, so here is a list of possible answers. Along with the standard "yes" and "no", various adverbs can be used as well.
 * Ja. ― "Yes."
 * Nein. ― "No."
 * Vielleicht. ― "Maybe."
 * Natürlich. ― "Yes, of course."
 * Gern. ― "Yes, gladly."

With a negative question you can respond with Doch. There's no equivalent word in English but it's meaning is something like "to the contrary."
 * Hörst du nicht? ― "Don't you hear?"
 * Doch. ― "To the contrary, I can."

If you want to explain your answer, the natural thing to do is combine it with a statement:
 * Schläfst du? ― "Are you sleeping?"
 * Nein, ich arbeite. ― "No, I'm working."

Preambles and postambles
As seen in the previous example, German provides a mechanism to tack a word or two to the beginning or end of a sentence. This works in about the same way as in English, and the added words have no effect on the grammar of the rest of the sentence. Possible words include the answer to a question (as above), various interjections, and a name if you want to get someone's attention or make it clear who you're talking to.
 * Hilfe, ich falle! ― "Help, I'm falling!"
 * Schläfst du, Sara? ― "Are you sleeping, Sara?"

Tag questions form another common type of postamble. Some examples in English are "eh?" and "right?"; these are added to the end of a statement to ask for agreement from the listener. Some phrases like this in German are:
 * nicht? ― "no?"
 * was? ― "what?"
 * richig? ― "right?"
 * oder? ― "or?"
 * This one is somewhat unusual in that the counterpart in English can't be used in a similar way.
 * nicht wahr? ― "isn't it true?"

As in English, this type of phrase is highly susceptible to regional variation, so there are many other such phrases used only by people with specific accents.

There are, of course, technical terms for this kind of thing, but since both the mechanism and meaning should be familiar to English speakers already, there is no need to go into the jargon here.

title: German/Grammar/Polar questions


text:
User talk:AnotherEditor144

Welcome!
Welcome to Wikibooks, AnotherEditor144!

 First steps tutorial Wikibooks is for collaborative development of free textbooks.

You do not need technical skills to contribute. You can easily change most books. Please introduce yourself, and let us know what interests you.

If you already contribute at other Wikimedia projects, our Wikimedia Orientation should quickly get you started. (Would you like to provide feedback on this message?)

  Getting help   Made a mistake?   Goodies, tips and tricks
 * Read the Using Wikibooks book for a friendly introduction to the project, or our help pages for more information.
 * You can get friendly help from the community in the user assistance room or our IRC channel.
 * Upload freely licensed files to Wikimedia Commons. You may request permission to upload fair use files locally. Please include author and source information and a non-free use rationale for non-free files.
 * You can restore a previously saved version.
 * Pages should follow the  naming convention.
 * Need to rename a page? Use the move tab (is available once your account is 4 days old - until then, ask for help).
 * To request a page be deleted, add to the top of the page.
 * Was a page you made deleted? Please read the deletion policy, and check the deletion log to find out why. Also check the RFD archives if applicable. You can request undeletion at WB:RFU, or ask the administrator who deleted the page.
 * Please fill in the edit summary and preview your edits before saving.
 * Sign your name on discussion pages by typing ~~~~
 * User scripts can make many tasks easier. Look at the Gadgets tab of my preferences; check off the boxes for the scripts you want, and hit save!

-- Jules (Mrjulesd) 14:49, 1 March 2021 (UTC)

, thanks, although my main wiki is. I meant. Sorry. AnotherEditor144 t - c 14:53, 1 March 2021 (UTC)

 * I stumbled across this, but you need to stop being so surprised if someone leaves you a message on a userpage that is not your en.ws page. Not to forget the reasons that @Liuxinyu970226 had already given you here. SHB2000 (discuss • contribs) 03:56, 22 January 2022 (UTC)

title: User talk:AnotherEditor144


text:
User talk:YavBav09

Welcome!
Welcome to Wikibooks, YavBav09!

 First steps tutorial Wikibooks is for collaborative development of free textbooks.

You do not need technical skills to contribute. You can easily change most books. Please introduce yourself, and let us know what interests you.

If you already contribute at other Wikimedia projects, our Wikimedia Orientation should quickly get you started. (Would you like to provide feedback on this message?)

  Getting help   Made a mistake?   Goodies, tips and tricks
 * Read the Using Wikibooks book for a friendly introduction to the project, or our help pages for more information.
 * You can get friendly help from the community in the user assistance room or our IRC channel.
 * Upload freely licensed files to Wikimedia Commons. You may request permission to upload fair use files locally. Please include author and source information and a non-free use rationale for non-free files.
 * You can restore a previously saved version.
 * Pages should follow the  naming convention.
 * Need to rename a page? Use the move tab (is available once your account is 4 days old - until then, ask for help).
 * To request a page be deleted, add to the top of the page.
 * Was a page you made deleted? Please read the deletion policy, and check the deletion log to find out why. Also check the RFD archives if applicable. You can request undeletion at WB:RFU, or ask the administrator who deleted the page.
 * Please fill in the edit summary and preview your edits before saving.
 * Sign your name on discussion pages by typing ~~~~
 * User scripts can make many tasks easier. Look at the Gadgets tab of my preferences; check off the boxes for the scripts you want, and hit save!

-- Jules (Mrjulesd) 14:50, 1 March 2021 (UTC)

title: User talk:YavBav09


text:
Oberon/V2/Curves

MODULE Curves; (*NW 8.11.90 / 1.2.91*) IMPORT Display, Files, Printer, Oberon, Graphics, GraphicFrames; TYPE Curve* = POINTER TO CurveDesc; CurveDesc* = RECORD (Graphics.ObjectDesc) kind*, lw*: INTEGER END ; (*kind: 0 = up-line, 1 = down-line, 2 = circle, 3 = ellipse*) VAR method*: Graphics.Method; PROCEDURE dot(f: GraphicFrames.Frame; col: INTEGER; x, y: LONGINT); BEGIN IF (f.X <= x) & (x < f.X1) & (f.Y <= y) & (y < f.Y1) THEN Display.Dot(col, x, y, 0) END END dot; PROCEDURE mark(f: GraphicFrames.Frame; col, x, y: INTEGER); BEGIN IF (f.X <= x) & (x+4 < f.X1) & (f.Y <= y) & (y+4 < f.Y1) THEN Display.ReplConst(col, x, y, 4, 4, 0) END END mark; PROCEDURE line(f: GraphicFrames.Frame; col: INTEGER; x, y, w, h, d: LONGINT); VAR x1, y1, u: LONGINT; BEGIN IF h < w THEN x1 := x+w; u := (h-w) DIV 2; IF d = -1 THEN INC(y, h) END ; WHILE x < x1 DO 				dot(f, col, x, y); INC(x); IF u < 0 THEN INC(u, h) ELSE INC(u, h-w); INC(y, d) END END ELSE y1 := y+h; u := (w-h) DIV 2; IF d = -1 THEN INC(x, w) END ; WHILE y < y1 DO 				dot(f, col, x, y); INC(y); IF u < 0 THEN INC(u, w) ELSE INC(u, w-h); INC(x, d) END END END END line; PROCEDURE circle(f: GraphicFrames.Frame; col: INTEGER; x0, y0, r: LONGINT); VAR x, y, u: LONGINT; BEGIN u := 1 - r; x := r; y := 0; WHILE y <= x DO 			dot(f, col, x0+x, y0+y); dot(f, col, x0+y, y0+x); dot(f, col, x0-y, y0+x); dot(f, col, x0-x, y0+y); dot(f, col, x0-x, y0-y); dot(f, col, x0-y, y0-x); dot(f, col, x0+y, y0-x); dot(f, col, x0+x, y0-y); IF u < 0 THEN INC(u, 2*y+3) ELSE INC(u, 2*(y-x)+5); DEC(x) END ; INC(y) END END circle; PROCEDURE ellipse(f: GraphicFrames.Frame; col: INTEGER; x0, y0, a, b: LONGINT); VAR x, y, y1, aa, bb, d, g, h: LONGINT; BEGIN aa := a*a; bb := b*b; h := (aa DIV 4) - b*aa + bb; g := (9*aa DIV 4) - 3*b*aa + bb; x := 0; y := b; 		WHILE g < 0 DO 			dot(f, col, x0+x, y0+y); dot(f, col, x0-x, y0+y); dot(f, col, x0-x, y0-y); dot(f, col, x0+x, y0-y); IF h < 0 THEN d := (2*x+3)*bb; INC(g, d) 			ELSE d := (2*x+3)*bb - 2*(y-1)*aa; INC(g, d + 2*aa); DEC(y) END ; INC(h, d); INC(x) END ; y1 := y; h := (bb DIV 4) - a*bb + aa; x := a; y := 0; WHILE y <= y1 DO 			dot(f, col, x0+x, y0+y); dot(f, col, x0-x, y0+y); dot(f, col, x0-x, y0-y); dot(f, col, x0+x, y0-y); IF h < 0 THEN INC(h, (2*y+3)*aa) ELSE INC(h, (2*y+3)*aa - 2*(x-1)*bb); DEC(x) END ; INC(y) END END ellipse; PROCEDURE New*; VAR c: Curve; BEGIN NEW(c); c.do := method; Graphics.new := c 	END New; PROCEDURE* Copy(src, dst: Graphics.Object); BEGIN dst(Curve)^ := src(Curve)^ END Copy; PROCEDURE* Draw(obj: Graphics.Object; VAR M: Graphics.Msg); VAR x, y, w, h, col: INTEGER; f: GraphicFrames.Frame; BEGIN WITH M: GraphicFrames.DrawMsg DO 			x := obj.x + M.x; y := obj.y + M.y; w := obj.w; h := obj.h; f := M.f; 			IF M.col = Display.black THEN col := obj.col ELSE col := M.col END ; IF (x < f.X1) & (f.X <= x+w) & (y < f.Y1) & (f.Y <= y+h) THEN IF obj(Curve).kind = 0 THEN (*up-line*) IF M.mode = 0 THEN IF obj.selected THEN mark(f, Display.white, x, y) END ; line(f, col, x, y, w, h, 1) ELSIF M.mode = 1 THEN mark(f, Display.white, x, y) 					ELSIF M.mode = 2 THEN mark(f, Display.black, x, y) 					ELSE mark(f, Display.black, x, y); line(f, Display.black, x, y, w, h, 1) END ELSIF obj(Curve).kind = 1 THEN (*down-line*) IF M.mode = 0 THEN IF obj.selected THEN mark(f, Display.white, x, y+h) END ; line(f, col, x, y, w, h, -1) ELSIF M.mode = 1 THEN mark(f, Display.white, x, y+h) ELSIF M.mode = 2 THEN mark(f, Display.black, x, y+h) ELSE mark(f, Display.black, x, y+h); line(f, Display.black, x, y, w, h, -1) END ELSIF obj(Curve).kind = 2 THEN (*circle*) w := w DIV 2; IF M.mode = 0 THEN IF obj.selected THEN mark(f, Display.white, x+w, y-4) END ; circle(f, col, x+w, y+w, w) 					ELSIF M.mode = 1 THEN mark(f, Display.white, x+w, y-4) ELSIF M.mode = 2 THEN mark(f, Display.black, x+w, y-4) ELSE mark(f, Display.black, x+w, y-4); circle(f, Display.black, x+w, y+w, w) 					END ELSIF obj(Curve).kind = 3 THEN (*ellipse*) w := w DIV 2; h := h DIV 2; IF M.mode = 0 THEN IF obj.selected THEN mark(f, Display.white, x+w, y-4) END ; ellipse(f, col, x+w, y+h, w, h) 					ELSIF M.mode = 1 THEN mark(f, Display.white, x+w, y-4) ELSIF M.mode = 2 THEN mark(f, Display.black, x+w, y-4) ELSE mark(f, Display.black, x+w, y-4); ellipse(f, Display.black, x+w, y+h, w, h) 					END END END END END Draw; PROCEDURE* Selectable(obj: Graphics.Object; x, y: INTEGER): BOOLEAN; VAR xm, y0, w, h: INTEGER; BEGIN IF obj(Curve).kind <= 1 THEN (*line*) w := obj.w; h := obj.h; 			IF obj(Curve).kind = 1 THEN y0 := obj.y + h; h := -h ELSE y0 := obj.y END ; RETURN (obj.x <= x) & (x < obj.x + w) & (ABS(LONG(y-y0)*w - LONG(x-obj.x)*h) < w*4) ELSE (*circle or ellipse*) xm := obj.w DIV 2 + obj.x; 			RETURN (xm - 4 <= x) & (x <= xm + 4) & (obj.y - 4 <= y) & (y <= obj.y + 4) END END Selectable; PROCEDURE* Handle(obj: Graphics.Object; VAR M: Graphics.Msg); BEGIN IF M IS Graphics.ColorMsg THEN obj.col := M(Graphics.ColorMsg).col END END Handle; PROCEDURE* Read(obj: Graphics.Object; VAR R: Files.Rider; VAR C: Graphics.Context); VAR len: SHORTINT; BEGIN Files.Read(R, len); Graphics.ReadInt(R, obj(Curve).kind); Graphics.ReadInt(R, obj(Curve).lw) END Read; PROCEDURE* Write(obj: Graphics.Object; cno: SHORTINT; 		VAR W: Files.Rider; VAR C: Graphics.Context); BEGIN Graphics.WriteObj(W, cno, obj); Files.Write(W, 4); Graphics.WriteInt(W, obj(Curve).kind); Graphics.WriteInt(W, obj(Curve).lw) END Write; PROCEDURE* Print(obj: Graphics.Object; x, y: INTEGER); VAR x0, y0: INTEGER; BEGIN IF obj(Curve).kind = 0 THEN x0 := obj.x * 4 + x; y0 := obj.y * 4 + y; 			Printer.Line(x0, y0, obj.w * 4 + x0, obj.h * 4 + y0) ELSIF obj(Curve).kind = 1 THEN x0 := obj.x * 4 + x; y0 := obj.y * 4 + y; 			Printer.Line(x0, obj.h * 4 + y0, obj.w * 4 + x0, y0) ELSIF obj(Curve).kind = 2 THEN Printer.Circle((obj.x*2 + obj.w)*2 + x, (obj.y*2 + obj.h)*2 + y, obj.w*2) ELSE Printer.Ellipse((obj.x*2 + obj.w)*2 + x, (obj.y*2 + obj.h)*2 + y, obj.w*2, obj.h*2) END END Print; PROCEDURE MakeLine*; (*command*) VAR x0, x1, y0, y1: INTEGER; c: Curve; G: GraphicFrames.Frame; BEGIN G := GraphicFrames.Focus; IF (G # NIL) & (G.mark.next # NIL) THEN GraphicFrames.Deselect(G); x0 := G.mark.x; y0 := G.mark.y; x1 := G.mark.next.x; y1 := G.mark.next.y; 			NEW(c); c.col := Oberon.CurCol; c.w := ABS(x1-x0); c.h := ABS(y1-y0); c.lw := Graphics.width; IF x0 <= x1 THEN c.x := x0; IF y0 <= y1 THEN c.kind := 0; c.y := y0 ELSE c.kind := 1; c.y := y1 END ELSE c.x := x1; IF y1 < y0 THEN c.kind := 0; c.y := y1 ELSE c.kind := 1; c.y := y0 END END ; DEC(c.x, G.x); DEC(c.y, G.y); c.do := method; Graphics.Add(G.graph, c); GraphicFrames.Defocus(G); GraphicFrames.DrawObj(G, c) 		END END MakeLine; PROCEDURE MakeCircle*; (*command*) VAR x0, y0, r: INTEGER; c: Curve; G: GraphicFrames.Frame; BEGIN G := GraphicFrames.Focus; IF (G # NIL) & (G.mark.next # NIL) THEN GraphicFrames.Deselect(G); x0 := G.mark.x; y0 := G.mark.y; r := ABS(G.mark.next.x-x0); IF r > 4 THEN NEW(c); c.x := x0 - r - G.x; c.y := y0 - r - G.y; c.w := 2*r+1; c.h := c.w; 				c.kind := 2; c.col := Oberon.CurCol; c.lw := Graphics.width; c.do := method; Graphics.Add(G.graph, c); GraphicFrames.Defocus(G); GraphicFrames.DrawObj(G, c) 			END END END MakeCircle; PROCEDURE MakeEllipse*; (*command*) VAR x0, y0, a, b: INTEGER; c: Curve; G: GraphicFrames.Frame; BEGIN G := GraphicFrames.Focus; IF (G # NIL) & (G.mark.next # NIL) & (G.mark.next.next # NIL) THEN GraphicFrames.Deselect(G); x0 := G.mark.x; y0 := G.mark.y; 			a := ABS(G.mark.next.x-x0); b := ABS(G.mark.next.next.y - y0); IF (a > 4) & (b > 4) THEN NEW(c); c.x := x0 - a - G.x; c.y := y0 - b - G.y; c.w := 2*a+1; c.h := 2*b+1; c.kind := 3; c.col := Oberon.CurCol; c.lw := Graphics.width; c.do := method; Graphics.Add(G.graph, c); GraphicFrames.Defocus(G); GraphicFrames.DrawObj(G, c) 			END END END MakeEllipse; BEGIN NEW(method); method.module := "Curves"; method.allocator := "New"; method.new := New; method.copy := Copy; method.draw := Draw; method.selectable := Selectable; method.handle := Handle; method.read := Read; method.write := Write; method.print := Print END Curves.

title: Oberon/V2/Curves


text:
Oberon/V2/Rectangles

MODULE Rectangles; (*NW 25.2.90 / 1.2.92*) IMPORT Display, Files, Input, Printer, Texts, Oberon, Graphics, GraphicFrames; TYPE Rectangle* = POINTER TO RectDesc; RectDesc* = RECORD (Graphics.ObjectDesc) lw*, vers*: INTEGER END ; VAR method*: Graphics.Method; shade: INTEGER; PROCEDURE New*; VAR r: Rectangle; BEGIN NEW(r); r.do := method; Graphics.new := r 	END New; PROCEDURE* Copy(src, dst: Graphics.Object); BEGIN dst(Rectangle)^ := src(Rectangle)^ END Copy; PROCEDURE mark(col, x, y: INTEGER); BEGIN Display.ReplConst(col, x-4, y, 4, 4, 0) END mark; PROCEDURE* Draw(obj: Graphics.Object; VAR M: Graphics.Msg); VAR x, y, w, h, lw, col: INTEGER; s: SET; f: GraphicFrames.Frame; PROCEDURE draw(col: INTEGER); BEGIN IF 0 IN s THEN Display.ReplConst(col, x, y, w, lw, 0) END ; IF 1 IN s THEN Display.ReplConst(col, x+w-lw, y, lw, h, 0) END ; IF 2 IN s THEN Display.ReplConst(col, x, y+h-lw, w, lw, 0) END ; IF 3 IN s THEN Display.ReplConst(col, x, y, lw, h, 0) END END draw; BEGIN WITH M: GraphicFrames.DrawMsg DO 			x := obj.x + M.x; y := obj.y + M.y; w := obj.w; h := obj.h; f := M.f; 			lw := obj(Rectangle).lw; s := {0..3}; IF x+w < f.X THEN s := {} ELSIF x < f.X THEN DEC(w, f.X-x); x := f.X; EXCL(s, 3) END ; IF x >= f.X1 THEN s := {} ELSIF x+w > f.X1 THEN w := f.X1-x; EXCL(s, 1) END ; IF y+h < f.Y THEN s := {} ELSIF y < f.Y THEN DEC(h, f.Y-y); y := f.Y; EXCL(s, 0) END ; IF y >= f.Y1 THEN s := {} ELSIF y+h > f.Y1 THEN h := f.Y1-y; EXCL(s, 2) END ; IF s # {} THEN IF M.col = Display.black THEN col := obj.col ELSE col := M.col END ; IF M.mode = 0 THEN draw(col); IF obj.selected THEN mark(Display.white, x+w-lw, y+lw) END ; IF obj(Rectangle).vers # 0 THEN Display.ReplPattern(col, Display.grey0, x, y, w, h, 1) END ELSIF M.mode = 1 THEN mark(Display.white, x+w-lw, y+lw) ELSIF M.mode = 2 THEN mark(Display.black, x+w-lw, y+lw) ELSIF obj(Rectangle).vers = 0 THEN draw(Display.black); mark(Display.black, x+w-lw, y+lw) ELSE Display.ReplConst(Display.black, x, y, w, h, 0) END END END END Draw; PROCEDURE* Selectable(obj: Graphics.Object; x, y: INTEGER): BOOLEAN; BEGIN RETURN (obj.x + obj.w - 4 <= x) & (x <= obj.x + obj.w) & (obj.y <= y) & (y <= obj.y + 4) END Selectable; PROCEDURE* Handle(obj: Graphics.Object; VAR M: Graphics.Msg); VAR x0, y0, x1, y1, dx, dy: INTEGER; k: SET; BEGIN IF M IS Graphics.WidMsg THEN obj(Rectangle).lw := M(Graphics.WidMsg).w 		ELSIF M IS Graphics.ColorMsg THEN obj.col := M(Graphics.ColorMsg).col ELSIF M IS GraphicFrames.CtrlMsg THEN WITH M: GraphicFrames.CtrlMsg DO 				WITH obj: Rectangle DO 					M.res := 1; x0 := obj.x + obj.w + M.f.x; y0 := obj.y + M.f.y; 					mark(Display.white, x0 - obj.lw, y0 + obj.lw); REPEAT Input.Mouse(k, x1, y1); DEC(x1, (x1-M.f.x) MOD 4); DEC(y1, (y1-M.f.y) MOD 4); Oberon.DrawCursor(Oberon.Mouse, GraphicFrames.Crosshair, x1, y1) UNTIL k = {}; mark(Display.black, x0 - obj.lw, y0 + obj.lw); IF (x0 - obj.w < x1) & (y1 < y0+ obj.h) THEN GraphicFrames.EraseObj(M.f, obj); dx := x1 - x0; dy := y1 - y0; INC(obj.y, dy); INC(obj.w, dx); DEC(obj.h, dy); GraphicFrames.DrawObj(M.f, obj) END END END END END Handle; PROCEDURE* Read(obj: Graphics.Object; VAR R: Files.Rider; VAR C: Graphics.Context); VAR w, v, len: SHORTINT; BEGIN Files.Read(R, len); Files.Read(R, w); Files.Read(R, v); obj(Rectangle).lw := w; obj(Rectangle).vers := v 	END Read; PROCEDURE* Write(obj: Graphics.Object; cno: SHORTINT; 			VAR W: Files.Rider; VAR C: Graphics.Context); BEGIN Graphics.WriteObj(W, cno, obj); Files.Write(W, 2); Files.Write(W, SHORT(obj(Rectangle).lw)); Files.Write(W, SHORT(obj(Rectangle).vers)) END Write; PROCEDURE* Print(obj: Graphics.Object; x, y: INTEGER); VAR w, h, lw, s: INTEGER; BEGIN INC(x, obj.x * 4); INC(y, obj.y * 4); w := obj.w * 4; h := obj.h * 4; lw := obj(Rectangle).lw * 2; s := obj(Rectangle).vers; Printer.ReplConst(x, y, w, lw); Printer.ReplConst(x+w-lw, y, lw, h); Printer.ReplConst(x, y+h-lw, w, lw); Printer.ReplConst(x, y, lw, h); IF s > 0 THEN Printer.ReplPattern(x, y, w, h, s) END END Print; PROCEDURE Make*; (*command*) VAR x0, x1, y0, y1: INTEGER; R: Rectangle; G: GraphicFrames.Frame; BEGIN G := GraphicFrames.Focus; IF (G # NIL) & (G.mark.next # NIL) THEN GraphicFrames.Deselect(G); x0 := G.mark.x; y0 := G.mark.y; x1 := G.mark.next.x; y1 := G.mark.next.y; 			NEW(R); R.col := Oberon.CurCol; R.w := ABS(x1-x0); R.h := ABS(y1-y0); IF x1 < x0 THEN x0 := x1 END ; IF y1 < y0 THEN y0 := y1 END ; R.x := x0 - G.x; R.y := y0 - G.y; 			R.lw := Graphics.width; R.vers := shade; R.do := method; Graphics.Add(G.graph, R); GraphicFrames.Defocus(G); GraphicFrames.DrawObj(G, R) 		END END Make; PROCEDURE SetShade*; VAR S: Texts.Scanner; BEGIN Texts.OpenScanner(S, Oberon.Par.text, Oberon.Par.pos); Texts.Scan(S); IF S.class = Texts.Int THEN shade := SHORT(S.i) END END SetShade; BEGIN shade := 0; NEW(method); method.module := "Rectangles"; method.allocator := "New"; method.new := New; method.copy := Copy; method.draw := Draw; method.selectable := Selectable; method.handle := Handle; method.read := Read; method.write := Write; method.print := Print END Rectangles.

title: Oberon/V2/Rectangles


text: User:Birthmark On Temple

title: User:Birthmark On Temple


text:
Wikibooks:Collections/History of video games

History of Video Games

 * Introduction
 * Collections/Preface
 * History of video games
 * History of video games/Introduction
 * History of video games/Understanding Historical Technology

 * Timeline
 * History of video games/Early games
 * History of video games/Early games/Dr. Nim
 * History of video games/1960-1969
 * History of video games/1970-1979
 * History of video games/1980-1989
 * History of video games/1990-1999
 * History of video games/2000-2009
 * History of video games/2010-2019
 * History of video games/2020-2029

 * Arcade History
 * History of video games/Games/Pong and Breakout
 * History of video games/Golden age of arcade games
 * History of video games/Arcades after the golden age

 * Computer Gaming
 * History of video games/Computer games
 * History of video games/Platforms/Amiga
 * History of video games/Platforms/Amstrad CPC
 * History of video games/Platforms/Apple II
 * History of video games/Platforms/Atari 8 bit family
 * History of video games/Platforms/BBC Micro
 * History of video games/Platforms/Classic Mac
 * History of video games/Platforms/Commodore 64
 * History of video games/Platforms/FM Towns
 * History of video games/Platforms/IBM Personal Computer
 * History of video games/Platforms/MSX
 * History of video games/Platforms/PC-8800 series
 * History of video games/Platforms/Texas Instruments TI-99/4A
 * History of video games/Platforms/Windows 9x
 * History of video games/Platforms/ZX Spectrum

 * First Generation of Video Game Consoles
 * History of video games/First generation of video game consoles
 * History of video games/Platforms/APF TV Fun series
 * History of video games/Platforms/Atari Game Brain
 * History of video games/Platforms/BSS 01
 * History of video games/Platforms/Coleco Telstar series
 * History of video games/Platforms/Color TV-Game
 * History of video games/Platforms/Electro Tic-Tac-Toe
 * History of video games/Platforms/Gameroom Tele-Pong
 * History of video games/Platforms/Magnavox Odyssey
 * History of video games/Platforms/Merlin
 * History of video games/Platforms/Odyssey series
 * History of video games/Platforms/PC-50x Family
 * History of video games/Platforms/Pong consoles
 * History of video games/Platforms/TV Tennis Electrotennis

 * Second generation of video game consoles
 * History of video games/Second generation of video game consoles
 * History of video games/Platforms/1292 Advanced Programmable Video System
 * History of video games/Platforms/APF-MP1000
 * History of video games/Platforms/Arcadia 2001
 * History of video games/Platforms/Atari 2600
 * History of video games/Platforms/Atari 5200
 * History of video games/Platforms/Atari Cosmos
 * History of video games/Platforms/Astrocade
 * History of video games/Platforms/Bandai Super Vision 8000
 * History of video games/Platforms/Cassette Vision
 * History of video games/Platforms/Children's Discovery System
 * History of video games/Platforms/ColecoVision
 * History of video games/Platforms/Colorvision
 * History of video games/Platforms/Computer Mah-Jong Yakuman
 * History of video games/Platforms/Digi Casse
 * History of video games/Platforms/Entex Select-A-Game
 * History of video games/Platforms/Epoch Game Pocket Computer
 * History of video games/Platforms/Fairchild Channel F
 * History of video games/Platforms/Gakken Compact Vision TV Boy
 * History of video games/Platforms/Game & Watch series
 * History of video games/Platforms/Intellivision
 * History of video games/Platforms/Interton Video Computer 4000
 * History of video games/Platforms/Leisure Vision
 * History of video games/Platforms/Magnavox Odyssey²
 * History of video games/Platforms/Microvision
 * History of video games/Platforms/Palladium Tele-Cassetten Game
 * History of video games/Platforms/Palmtex Portable Videogame System
 * History of video games/Platforms/Pyūta Jr
 * History of video games/Platforms/RCA Studio II
 * History of video games/Platforms/Entex Adventure Vision
 * History of video games/Platforms/SHG Black Point
 * History of video games/Platforms/Tele-Fever
 * History of video games/Platforms/Tomytronic 3D
 * History of video games/Platforms/Ultravision Video Arcade System
 * History of video games/Platforms/Vectrex
 * History of video games/Platforms/VTech 3D Gamate
 * History of video games/Platforms/VTech CreatiVision
 * History of video games/Platforms/VTech Variety

 * Third generation of video game consoles
 * History of video games/Third generation of video game consoles
 * History of video games/Platforms/Action Max
 * History of video games/Platforms/Amstrad GX4000
 * History of video games/Platforms/Atari 7800
 * History of video games/Platforms/Atari XEGS
 * History of video games/Platforms/BBC Bridge Companion
 * History of video games/Platforms/Commodore 64 Games System
 * History of video games/Platforms/Connor Videosmarts
 * History of video games/Platforms/Control-Vision
 * History of video games/Platforms/Etch-A-Sketch Animator 2000
 * History of video games/Platforms/Halcyon
 * History of video games/Platforms/IM-26
 * History of video games/Platforms/Light Games
 * History of video games/Platforms/LJN Video Art
 * History of video games/Platforms/Master System
 * History of video games/Platforms/My Vision
 * History of video games/Platforms/Nintendo Entertainment System
 * History of video games/Platforms/Philips Videopac+ G7400
 * History of video games/Platforms/PreComputer 1000
 * History of video games/Platforms/Proscreen
 * History of video games/Platforms/PV-1000
 * History of video games/Platforms/SG-1000
 * History of video games/Platforms/Super Cassette Vision
 * History of video games/Platforms/Video Challenger
 * History of video games/Platforms/Vidéoway
 * History of video games/Platforms/View-Master Interactive Vision
 * History of video games/Platforms/VTech Socrates
 * History of video games/Platforms/Zemmix

 * Fourth generation of video game consoles
 * History of video games/Fourth generation of video game consoles
 * History of video games/Platforms/Atari Lynx
 * History of video games/Platforms/Atari Panther
 * History of video games/Platforms/Barcode Battler
 * History of video games/Platforms/Capcom Power System Changer
 * History of video games/Platforms/CD-i
 * History of video games/Platforms/Commodore CDTV
 * History of video games/Platforms/Gamate
 * History of video games/Platforms/Game Boy
 * History of video games/Platforms/Game Gear
 * History of video games/Platforms/Game Master
 * History of video games/Platforms/Konami Picno
 * History of video games/Platforms/Konix Multisystem
 * History of video games/Platforms/LaserActive
 * History of video games/Platforms/Mega Duck
 * History of video games/Platforms/NEO•GEO
 * History of video games/Platforms/Nintendo Mini Classics
 * History of video games/Platforms/PC Engine SuperGrafx
 * History of video games/Platforms/Sega Genesis
 * History of video games/Platforms/Sega Pico
 * History of video games/Platforms/Super A'Can
 * History of video games/Platforms/Super Nintendo Entertainment System
 * History of video games/Platforms/Tandy Video Information System
 * History of video games/Platforms/Terebikko
 * History of video games/Platforms/TurboDuo
 * History of video games/Platforms/TurboExpress
 * History of video games/Platforms/TurboGrafx-16
 * History of video games/Platforms/Watara Supervision
 * History of video games/Platforms/WOWOW

 * Fifth generation of video game consoles
 * History of video games/Fifth generation of video game consoles
 * History of video games/Platforms/3DO Interactive Multiplayer
 * History of video games/Platforms/Amiga CD32
 * History of video games/Platforms/Pippin
 * History of video games/Platforms/Atari Jaguar
 * History of video games/Platforms/Casio Loopy
 * History of video games/Platforms/Design Master Senshi Mangajukuu
 * History of video games/Platforms/FM Towns Marty
 * History of video games/Platforms/Game.com
 * History of video games/Platforms/Genesis Nomad
 * History of video games/Platforms/Hasbro Toaster VR
 * History of video games/Platforms/Neo Geo Pocket
 * History of video games/Platforms/Nintendo 64
 * History of video games/Platforms/PC-FX
 * History of video games/Platforms/Playdia
 * History of video games/Platforms/PlayStation
 * History of video games/Platforms/Pokémon Pikachu
 * History of video games/Platforms/R-Zone
 * History of video games/Platforms/Sega Saturn
 * History of video games/Platforms/Virtual Boy
 * History of video games/Platforms/WonderSwan

 * Sixth generation of video game consoles
 * History of video games/Sixth generation of video game consoles
 * History of video games/Platforms/ApeXtreme
 * History of video games/Platforms/Cybiko
 * History of video games/Platforms/digiBLAST
 * History of video games/Platforms/DISCover
 * History of video games/Platforms/Dreamcast
 * History of video games/Platforms/Game Boy Advance
 * History of video games/Platforms/GameCube
 * History of video games/Platforms/GameKing
 * History of video games/Platforms/GP32
 * History of video games/Platforms/GPANG
 * History of video games/Platforms/L600
 * History of video games/Platforms/N-Gage
 * History of video games/Platforms/Nuon
 * History of video games/Platforms/Panasonic M2
 * History of video games/Platforms/Pelican VG Pocket
 * History of video games/Platforms/Pepper Pad
 * History of video games/Platforms/Phantom
 * History of video games/Platforms/Pixter
 * History of video games/Platforms/PlayStation 2
 * History of video games/Platforms/Pokémon Mini
 * History of video games/Platforms/Red Jade
 * History of video games/Platforms/Tapwave Zodiac
 * History of video games/Platforms/V.Smile
 * History of video games/Platforms/Xavix
 * History of video games/Platforms/Xbox
 * History of video games/Platforms/XGameStation

 * Seventh generation of video game consoles
 * History of video games/Seventh generation of video game consoles
 * History of video games/Platforms/Coleco Sonic
 * History of video games/Platforms/DIFRNCE MGC01
 * History of video games/Platforms/Dingoo
 * History of video games/Platforms/EVO Smart Console
 * History of video games/Platforms/GamBros
 * History of video games/Platforms/Game Wave Family Entertainment System
 * History of video games/Platforms/Gizmondo
 * History of video games/Platforms/GP2X
 * History of video games/Platforms/GP2X Caanoo
 * History of video games/Platforms/GP2X Wiz
 * History of video games/Platforms/HYDRA Game Development Kit
 * History of video games/Platforms/HyperScan
 * History of video games/Platforms/JXD 1000
 * History of video games/Platforms/LeapFrog Didj
 * History of video games/Platforms/Leapster Explorer
 * History of video games/Platforms/Mi2
 * History of video games/Platforms/Nintendo DS
 * History of video games/Platforms/Pandora
 * History of video games/Platforms/PlayStation 3
 * History of video games/Platforms/PlayStation Portable
 * History of video games/Platforms/Pocket Dream Console
 * History of video games/Platforms/Swinxs
 * History of video games/Platforms/UzeBox
 * History of video games/Platforms/V.Flash
 * History of video games/Platforms/VIA MOMA
 * History of video games/Platforms/Vii
 * History of video games/Platforms/Wii
 * History of video games/Platforms/Xbox 360
 * History of video games/Platforms/XGP
 * History of video games/Platforms/Zeebo

 * Eighth generation of video game consoles
 * History of video games/Eighth generation of video game consoles
 * History of video games/Platforms/3DS
 * History of video games/Platforms/Adafruit PyGamer
 * History of video games/Platforms/Arduboy
 * History of video games/Platforms/Chameleon
 * History of video games/Platforms/Clockwork GameShell
 * History of video games/Platforms/Creoqode 2048
 * History of video games/Platforms/Fuze Tomahawk F1
 * History of video games/Platforms/Game Gadget
 * History of video games/Platforms/Gamebuino
 * History of video games/Platforms/GameStick
 * History of video games/Platforms/Kano Pixel
 * History of video games/Platforms/Kitronik GameZip 64
 * History of video games/Platforms/LeapTV
 * History of video games/Platforms/M.O.J.O.
 * History of video games/Platforms/Neo Geo X
 * History of video games/Platforms/NES Classic Edition
 * History of video games/Platforms/Nvidia Shield Portable
 * History of video games/Platforms/Nvidia Shield TV
 * History of video games/Platforms/Ouya
 * History of video games/Platforms/Panasonic Jungle
 * History of video games/Platforms/PlayStation 4
 * History of video games/Platforms/PlayStation Classic
 * History of video games/Platforms/PlayStation Vita
 * History of video games/Platforms/Pokitto
 * History of video games/Platforms/Razer Forge TV
 * History of video games/Platforms/Steam Machines
 * History of video games/Platforms/Super NES Classic Edition
 * History of video games/Platforms/Switch
 * History of video games/Platforms/TinyDuino
 * History of video games/Platforms/Wii U
 * History of video games/Platforms/Xbox One
 * History of video games/Platforms/Xperia Play
 * History of video games/Platforms/ZTE Fun Box
 * History of video games/Platforms/ZX Spectrum Vega
 * History of video games/Platforms/ZX Spectrum Vega+

 * Ninth generation of video game consoles
 * History of video games/Ninth generation of video game consoles
 * History of video games/Platforms/32Blit
 * History of video games/Platforms/Atari VCS
 * History of video games/Platforms/BL6
 * History of video games/Platforms/DragonBox Pyra
 * History of video games/Platforms/Evercade
 * History of video games/Platforms/Game & Watch: Super Mario Bros.
 * History of video games/Platforms/Game Gear Micro
 * History of video games/Platforms/Intellivision Amico
 * History of video games/Platforms/KFConsole
 * History of video games/Platforms/Kittenbot MeowBit
 * History of video games/Platforms/LaserCube
 * History of video games/Platforms/Moranbong
 * History of video games/Platforms/Pimoroni PicoSystem
 * History of video games/Platforms/Playdate
 * History of video games/Platforms/PlayStation 5
 * History of video games/Platforms/Subor Z+
 * History of video games/Platforms/Tesla Arcade
 * History of video games/Platforms/Xbox Series

 * Cloud gaming history
 * History of video games/Platforms
 * History of video games/Platforms/AirConsole
 * History of video games/Platforms/Gaikai
 * History of video games/Platforms/GeForce Now
 * History of video games/Platforms/Google Stadia
 * History of video games/Platforms/Luna
 * History of video games/Platforms/OnLive
 * History of video games/Platforms/PlayStation Now
 * History of video games/Platforms/Shinra Technologies
 * History of video games/Platforms/Xbox Game Pass cloud gaming

 * Standardized platforms
 * History of video games/Mobile
 * History of video games/Web
 * History of video games/Calculator
 * History of video games/Fantasy Computers

 * Extended Reality Gaming
 * History of video games/VR
 * History of video games/AR
 * History of video games/XR

 * Special topics
 * History of video games/Esports
 * History of video games/Etiquette
 * History of video games/Indie games
 * History of video games/Open games
 * History of video games/Preservation
 * History of video games/Retro gaming


text:
Applied Programming/Files

Computer Files
What is it?

When you use your computer to create things, those things are stored in units of information called files. A computer file can be a document you write with your word processor. A computer file can also be a graphical image from a digital camera or an image you create with a digital paintbrush, a piece of music, a video, or just about anything. Whatever it is, the computer stores that information as a file.

File sizes

Since data storage on computers is still limited, file sizes still matter. File sizes are always measured in bytes. A byte is a sequence of 8 bits (and remember, a bit is the smallest piece of digital information, 000 or 111). A single byte is enough bits to represent 256 numbers, because 28 = 2562. That also means a byte is big enough to represent a single letter in the ASCII encoding standard. Larger files are referred to in larger byte sizes. Terms include kilobyte (1000 bytes), megabyte (10002 bytes), gigabyte (10003 bytes), terabyte (10004 bytes), petabyte (10005 bytes).

File types

Computers store all files as binary data, long strings of 111s and 000s. Files represent all different types of data, however—like images, videos, documents, text files, and spreadsheets. Even applications are files. Each file has a type/kind/format, which is often reflected in its file extension. Each individual file in Windows (and most other operating systems) will also have a file attribute which sets a condition to the specific file. For example, you can't write new information to a file that has the read-only attribute turned on. A filename is just the name that a user or program titles the file to help identify what it is. An image file may be named something like kids-lake-2017.jpg. The name itself doesn't affect the contents of the file, so even if a video file is named something like image.mp4, it doesn't mean it's suddenly a picture file. Files in any operating system are stored on hard drives, optical drives, and other storage devices. The specific way a file is stored and organized is referred to as a file system, which starts with the root directory and then continues to countless subdirectories or folders.

File operations

Include:
 * Create a new file
 * Change the access permissions and attributes of a file
 * Open a file, which makes the file contents available to the program
 * Read data from a file
 * Write data to a file
 * Delete a file
 * Close a file, terminating the association between it and the program
 * Truncate a file, shortening it to a specified size within the file system without rewriting any content
 * Updating contents to an existing file
 * Searching data on a file

File Systems
In computing, a file system or filesystem (often abbreviated to fs) controls how data is stored and retrieved. Without a file system, data placed in a storage medium would be one large body of data with no way to tell where one piece of data stops and the next begins. By separating the data into pieces and giving each piece a name, the data is easily isolated and identified. Taking its name from the way paper-based data management system is named, each group of data is called a "file." The structure and logic rules used to manage the groups of data and their names is called a "file system."

A file system functions in much the same way a book's table of contents does. It is a way for the computer to refer to the location of data on the storage device. Where a book may refer to a chapter and range of pages, a file system does the same with directories and folders. A filename consists of a sequence of characters followed by an extension type, such as myfile.txt. If we were to continue the book analogy, a filename would be the title of the chapter, and the directory would be the chapter number or page range. Directories can structured so that they are flat/linear or hierarchical; meaning they can be either one long list of files, or stored within many different folders and sub-folders.

Common file systems include FAT32 and NTFS on Windows platforms and APFS on macOS.

What are they?
A text file (sometimes spelled textfile; an old alternative name is flatfile) is a kind of computer file that is structured as a sequence of lines of electronic text. A text file exists stored as data within a computer file system. In operating systems such as CP/M and MS-DOS, where the operating system does not keep track of the file size in bytes, the end of a text file is denoted by placing one or more special characters, known as an end-of-file marker, as padding after the last line in a text file. On modern operating systems such as Microsoft Windows and Unix-like systems, text files do not contain any special EOF character, because file systems on those operating systems keep track of the file size in bytes. There are for most text files a need to have end-of-line delimiters, which are done in a few different ways depending on operating system. Some operating systems with record-orientated file systems may not use new line delimiters and will primarily store text files with lines separated as fixed or variable length records.

What are they?
A binary file is a computer file that is not a text file. The term "binary file" is often used as a term meaning "non-text file". Many binary file formats contain parts that can be interpreted as text; for example, some computer document files containing formatted text, such as older Microsoft Word document files, contain the text of the document but also contain formatting information in binary form.

Binary files contain formatting information that only certain applications or processors can understand. While humans can read text files, binary files must be run on the appropriate software or processor before humans can read them. For example, only Microsoft Word and certain other word processing programs can interpret the formatting information in a Word document. Executable files, compiled programs, SAS and SPSS system files, spreadsheets, compressed files, and graphic (image) files are all examples of binary files.

Reading and Writing to files in C#
The StreamReader and StreamWriter tools are used in C# for reading and writing to files. The declaration “using System.IO;” must be included in the heading of the program for the classes to be accessible, and the StreamReader or StreamWriter object is created with the keyword “new”. For example, the below code will use a StreamReader object that we’ll name sr to read and display a file called “filename.txt”:

Reading and Writing to files in Python
The same program can be performed in Python with the following code.

Key Terms
Absolute Path - Contains the root element and the complete directory list required to locate the file.

Binary File - A computer file that is not a text file. The term "binary file" is often used as a term meaning "non-text file".

Directory structure - The way an operating system's file system and its files are displayed to the user.

Directory - A location for storing files on your computer. Directories are found in a hierarchical file system, such as Linux, MS-DOS, OS/2, and Unix.

File System - Alternatively referred to as file management or FS, a file system is a method of organizing and retrieving files from a storage medium.

File Utilities - Allow users to create, list, copy, move and delete files, and alter metadata.

Fully-Qualified File Name - A string that uniquely identifies a file stored on the computer by including the path, name, and extension of the file.

Metadata - Information that is typically associated with each file within a file system. File systems might store the file creation time, the time it was last accessed, etc.

Parent and Children - A parent directory houses "children" files or subdirectories. A child is a file or subdirectory housed in a parent directory.

Path - Complete location or name of where a computer, file, device, or web page is located.

Relative Path - Needs to be combined with another path in order to access a file.

Root - The highest-level directory in the file system hierarchy, found in UNIX-like operating systems.

Text File - A file that is structured as a sequence of lines of electronic text, it exists stored as data within a computer file system.

title: Applied Programming/Files


text:
History of video games/Print version

For technical reasons, the print version is split into multiple sections.

 * History of video games/Print version/Introduction
 * History of video games/Print version/Timeline
 * History of video games/Print version/Arcade games
 * History of video games/Print version/Computer games
 * History of video games/Print version/First Generation of Video Game Consoles
 * History of video games/Print version/Second Generation of Video Game Consoles
 * History of video games/Print version/Third Generation of Video Game Consoles
 * History of video games/Print version/Fourth Generation of Video Game Consoles
 * History of video games/Print version/Fifth Generation of Video Game Consoles
 * History of video games/Print version/Sixth Generation of Video Game Consoles
 * History of video games/Print version/Seventh Generation of Video Game Consoles
 * History of video games/Print version/Eighth Generation of Video Game Consoles
 * History of video games/Print version/Ninth Generation of Video Game Consoles
 * History of video games/Print version/Standardized platforms
 * History of video games/Print version/Cloud gaming
 * History of video games/Print version/Specialty topics

title: History of video games/Print version


text:
History of video games/Print version/Introduction

 * Wikibooks Preface

 * Introduction

 * Understanding Historical Technology


text:
History of video games/Print version/Timeline

 * Timeline


text:
History of video games/Print version/Arcade games

 * Arcade History


text:
History of video games/Print version/Computer games

 * Computer Gaming


text:
History of video games/Print version/First Generation of Video Game Consoles

 * First Generation of Video Game Consoles


text:
History of video games/Print version/Second Generation of Video Game Consoles

 * Second generation of video game consoles


text:
History of video games/Print version/Third Generation of Video Game Consoles

 * Third generation of video game consoles


text:
History of video games/Print version/Fourth Generation of Video Game Consoles

 * Fourth generation of video game consoles


text:
History of video games/Print version/Fifth Generation of Video Game Consoles

 * Fifth generation of video game consoles


text:
History of video games/Print version/Sixth Generation of Video Game Consoles

 * Sixth generation of video game consoles


text:
History of video games/Print version/Seventh Generation of Video Game Consoles

 * Seventh generation of video game consoles


text:
History of video games/Print version/Eighth Generation of Video Game Consoles

 * Eighth generation of video game consoles


text:
History of video games/Print version/Ninth Generation of Video Game Consoles

 * Ninth generation of video game consoles


text:
History of video games/Print version/Cloud gaming

 * Cloud gaming history


text:
History of video games/Print version/Standardized platforms

 * Standardized platforms

 * Extended Reality Gaming


text:
History of video games/Print version/Specialty topics

 * Special topics


text:
Talk:General Anatomy/Digestive System/Parts/Stomach/Part 3

The merge begins.--65.31.10.98 (discuss) 23:36, 1 March 2021 (UTC)


text:
Talk:C Programming/C Reference/nonstandard/strlcpy

Isn't there an error in the example? memcpy is only called if length is greater than stack_buffer, i.e. the copy remains empyt

Original: if (length < sizeof(stack_buffer)) { // it fit, use the stack buffer copy = stack_buffer; } else { // it was truncated, use a slower buffer on the heap: copy = malloc(length+1); if (copy != NULL) memcpy(copy, source, length+1); }

Suggestion: if (length < sizeof(stack_buffer)) { // it fit, use the stack buffer copy = stack_buffer; } else { // it was truncated, use a slower buffer on the heap: copy = malloc(length+1); } if (copy != NULL) memcpy(copy, source, length+1);


text:
Author's Right, Copyright and Free Licenses for Culture on the Web

 * Introduction to the FAQs
 * I – Definitions
 * II – Types of Content
 * Photographs
 * 2D-3D Reproductions
 * Texts
 * Databases
 * Open Data
 * Audio Content
 * III – Web Tools
 * Podcast and Webinar
 * Sharing
 * Websites
 * Domain Name
 * App
 * Social Network
 * Instant Messaging
 * IV – Licenses and Reuse
 * Data and Licenses
 * Images of Cultural Goods in Public Domain
 * Open Access and License: International Museum Cases
 * V – Problems and Solutions
 * Infringements
 * Contracts and Consents
 * Legal Notices
 * Exceptions


text:
Author's Right, Copyright and Free Licenses for Culture on the Web/Introduction to the FAQs

These FAQs are practical guidance for museums, archives and libraries which aim to clarify the opportunities and legal limits related to the reuse and dissemination of digital reproductions of cultural resources on the Web.

There is a lack of knowledge among cultural heritage professionals on issues concerning the daily practice of online cultural communication but which have legal implications that require the utmost attention in the re-use of cultural content online. How to clarify to the cultural community? We will never publish a book without mentioning the author, title and date of publication. On the Web we run the risk of doing so with texts, images or audiovisual documents: on websites and social platforms it is easy to come across numerous violations of copyright or other types of rules.

But in the era of global content sharing, museums, libraries and archives and, more generally, cultural heritage institutions, do not seem to be sufficiently aware of the extraordinary opportunities in terms of cultural, social and economic development or the community that derive from the adoption of open licenses on content in the public domain. This is demonstrated by a growing number of cultural institutions that have taken this path and by an increasingly international bibliography that analyses the impact of open access on cultural institutions and the public.

Our research group works in close contact and dialogue with experts from national and international associations and stakeholders so that with a general reflection on digital cultural contents we may hope for a greater flexibility and balance between exclusive rights and freedom of reproduction.

''Important: The FAQS make reference to the European copyright law, considering - whenever possible, also for the aim of practical format of the research work - the differences among the various legal systems, if relevant. In this English translation the expression copyright will be used to refer to both authors’ right and copyright, unless otherwise noted. This document is for information and disclosure purposes and does not constitute a technical and/or legal opinion. For specific cases, we recommend seeking advice on the particular situation.''

''We could not consider all the critical issues expressed by the reviewers. Some issues require further study and writing. We will therefore prepare the first draft, which represents our positions on the matters examined in the FAQs. The work will be released in CC BY-SA on the Wikibooks platform and we therefore invite colleagues to continue the work of review and improvement. We cannot deepen the national specificity of the different countries indicated by some colleagues and therefore, we invite you to implement the shared version with the specific national situations, if you wish to do so, as we are doing for Italy. It will also be possible to create concise versions for each such jurisdiction, as some colleagues are already doing, also with a translation into the appropriate language.''

Acknowledgment. A special thanks to Thomas Margoni, Professor of Intellectual Property Law, CiTiP, Faculty of Law, KU Leuven for his continuous cooperation in the review. We thank colleagues who have helped us with important observations and suggestions during the selection and revision of these FAQs, for their valuable contribution: Alberto Garlandini, President of ICOM International; Adele Maresca, President of ICOM Italy; Alastair Dunning, Delft University of Technology; Josu Aramberri, University of the Basque Country; Marta Arosio, Wikimedia Italy; Aura Bertoni, ASK Centre Bocconi University; Nicola Barbuti, University of Bari Aldo Moro; Niccolò Caranti, Wikimedia Italy; Roberto Caso, University of Trento; Antonella De Robbio, Open Access and Public Domain study group (GOAPD) AIB Italian Libraries Association; Giulia Dore, University of Trento; Sara Di Giorgio; Pierluigi Feliciati, University of Macerata; Vincenza Ferrara, Sapienza University of Rome; Luca Martinelli, Wikimedia Italy; Guido Noto La Diega, University of Stirling; Iolanda Pensa, Wikimedia Italy; Merete Sanderhoff, SMK – the national gallery of Denmark, Copenhagen; Erica da Silva Souza Lopes, Fundação Oswaldo Cruz; Chiara Storti, BNCF; Melissa Smith Levine, Director, Copyright Office, University of Michigan Library; Brigitte Vézina; Catrin Vimercati, InFormAzionI cultural association; Benedetta Ubertazzi, University of Milan Bicocca.


text:
Author's Right, Copyright and Free Licenses for Culture on the Web/Definitions

1. What does authors’ rights/copyright mean?
The set of rules that protect original literary and artistic works is called "author’s rights" in civil law countries (Italy, France, Germany, etc.) and "copyright" in common law countries (United Kingdom, United States, Australia, Canada).

Author’s rights/copyright provides for a series of rules that regulate the relationship between the author, the work and the public. It is part of intellectual property’s regulation which includes both copyright/author’s right and industrial property (patents, trademarks, designations of origin, utility models, topographies of semiconductor products, trade secrets and new plant varieties).

Author’s right consists of moral rights, aimed at protecting the author’s personality, and economic rights, aimed at guaranteeing the author a remuneration through the economic exploitation of the work. Author’s right arises at the moment of the creation of the work, without any formality and protects "literary and artistic works", whatever the way or form of their expression. The Berne Convention (an international agreement that established for the first time the mutual recognition of copyright/author’s right among the signatory parties) recognizes to the subscribing States the faculty to prescribe that literary and artistic works are protected only if fixed on a material support. The requirement of fixing the work on a material support, admitted by the Berne Convention, is typical of common law countries and, for example, has not been adopted by the Italian legislation on the matter. It should nevertheless be noted that, while different from fixation, recent CJEU case law requires an element of “objectivity” or “stability” for a work to qualify for protection (Levola case). The two systems of author’s right and copyright traditionally focus on two different profiles: the first on the author as "person", and the second on the "right to copy the work". Although these different approaches have some differences between each other (such as, for example, the different regulation of moral rights), they have evolved to play a very similar function and increasingly tend to converge over time in relation to the evolution of forms of online exploitation of works and, in the EU, to the process of harmonisation of copyright law.

 * Reference:

2. Which works are protected by Copyright Law?
Copyright rules are territorial and can potentially vary significantly from country to country. However, mainly due to international conventions such as the Berne Convention, the World Intellectual Property Organization (WIPO) Copyright Treaty (WCT) and the TRIPs Agreement there is a body of rules that finds if not common, at least coordinated application, internationally. Within the European Union, the process of copyright harmonization has greatly reduced the differences between the Member States’ legislation through at least 12 different directives starting since the early 1990s. In particular, aspects such as: main economic exploitation rights, exceptions and limitations, technological measures of protection, originality, concept of work and the duration of economic rights have been almost fully harmonized and we can certainly say that, right now, works receive very similar protection at the European level. However, copyright remains a national prerogative and therefore there is the Italian, French, German, etc. Copyright Act which will be similar in the many aspects subject to harmonization indicated above, but will maintain their own peculiarities. Original works within the literary, scientific and artistic field, are protected by the law whatever the mode or form of their expression (even if it must have a certain stability) if they are original in the sense of the author’s own intellectual creation. Originality is manifested through free and creative choices that allow the author to imprint their own personality onto the work. Databases are protected by copyright only if the selection or arrangement of the material can be considered as the author’s own intellectual creation. In this case, the protection regards the structure of the database and does not extend to the contents of the database, without prejudice to any other rights.

 * References:

3. Do all works have an author?
Yes, the work must be the result of the author’s own intellectual creation.

The author can choose how to reveal his authorship if under his own name, or under a pseudonym, or to remain anonymous. There are also some works, called orphan works, which are presumed to be still under Copyright Law protection, but whose rights holders are unknown or untraceable.

 * Reference:

4. What do joint works and collective works mean?
Joint works are formed by several authors’ contributions that cannot be separated or distinguished from each other (as in the case of a book written by several authors); collective works are, instead, created by several authors but the individual contributions remain distinct and autonomous and, therefore, separable from each other (such as an anthology).

5. What are moral rights and economic rights’ characteristics?
All European States grant the author a series of exclusive rights that fall into two categories: moral and economic rights. Moral rights are born with the intent to protect the artistic personality of the author. The Berne Convention requires the adhering States to recognize two forms of moral rights: the right of attribution and the right of integrity of the work, i.e. to oppose any deformation, mutilation or other modification, as well as any other act to the detriment of the work itself, which would harm the honor or reputation of the author. The specific regulation is left to the legislation of the individual States. Moral rights, which have not been subject to specific harmonization, are non transferable and often not renounceable (even if in some jurisdictions renunciation is possible). Their duration can vary considerably: the minimum established at international level is at least the same duration as economic rights, but often, particularly in continental Europe, they last much longer, for example in Italy they are not subject to any term, i.e. they are perpetual. Economic rights, on the other hand, concern the use and economic exploitation of the work. The author, in fact, can decide to transfer or license the use of these rights, freely or in exchange of a payment. Economic rights are the right to exploit the work in any manner and in any way, e.g.: to publish, reproduce, transcribe, perform, represent or act in public, communicate and make available to the public, distribute, translate, elaborate, modify, lend or rent the work.

 * References:

6. What is the term of protection granted by copyright?
According to Berne Convention, the national legislation can determine the conditions for the exercise of economic rights, which have an effect territorially limited to the Country which established them. The duration of the economic rights includes the author’s life and a period of 50 years after his death, but the States have the right to establish a longer duration. In the Countries of the European Union, economic rights expire 70 years after the death of the last of the authors (when the work enters the public domain). Specific provisions are indicated for certain categories of works (collective work, joint work, anonymous or pseudonymous work, unpublished work).

As indicated above, under the Berne Convention, the moral rights’ term cannot be shorter than the economic rights’ one and Member States may establish a longer term or make it imprescriptible.

Moreover, the 1947 Peace Treaty, which gave only the winning countries the possibility to extend the term of protection of the rights of their authors, adding also the years of war, extends the duration established by law by a further 7 years and 8 months. Subsequently, with the stipulation of the TRIPS Agreement of 1994 by most of the countries of the world, any discrimination between States at war was eliminated, therefore even countries that lost the war (e.g. Italy) can apply, in their own territory and in Europe, the same duration of the rights (76 years and eight months).

 * References:

7. To whom does the copyright belong when the work is created by an employee or in case of commissioned work?
In general in Europe, moral rights and economic rights belong to the author for the fact of creation and from the moment the work comes into existence. In some cases, economic rights belong to different subjects. For example, for works created on commission or by an employee, economic rights do not belong to the author but to the commissioning party or the employer, always within the limits indicated by the law (e.g. software, database) or the contract.

 * References:

8. What do related rights mean?
Related Rights (or “neighbouring rights”) intend to recognize and encourage the artistic effort (such as performing artists of musical or audiovisual works) or the economic investment of those who make a work accessible by the public (phonographic producers, radio and television broadcasters, film producers and now also publisher of press publications shared on the web, to whom the new DSM Directive recognizes a particular and short-time related right to receive economic compensation in case of online uses).

 * References:

9. Which materials are protected by related rights?
The materials protected by related rights provided by European Copyright law are:
 * for performers, the fixations of their performances;
 * for phonogram producers, the phonograms;
 * for the producers of the first fixations of films, the original and copies of their films;
 * for broadcasting organisations, the fixations of their broadcasts, whether these broadcasts are transmitted by wire or over the air, including by cable or satellite;
 * for press publishers, their press publications made available online to the public by information society service providers.

There are also other cases of works protected by EU Copyright law that are not mandatory (e.g. non-original photographs, critical editions, fonts, etc.).

 * References:

10. Are there any exceptions or limitations to the copyright?
Yes, the system of exceptions and limitations allow to correctly balance between the copyright with the public’s right of access to culture and free expression. In practice, in these cases it is possible to use content protected by copyright law without the authorization of the rights holder. The exceptions (e.g. illustrative purposes for educational use or scientific research, quotation, criticism...) exclude the applicability of Copyright, making free the use of the work; the limitations make the work usable without the need to seek the prior permission of the rights-holder, but provide for the payment of an equitable compensation (e.g. reprography, personal use). Directive 2001/29/EC identified a closed list (meaning that Member States cannot introduce unlisted exceptions) of non-mandatory exceptions leaving the national legislator the choice on their implementation and identifying in article 5, paragraph 1, only one mandatory exception in relation to certain temporary acts of reproduction. Other specific exceptions may be found in specific areas (e.g. Software, Databases, etc). On the contrary, the recent Directive 2019/790/EU overturns the previous approach by providing for three mandatory exceptions and, therefore, ensuring the effective reception of them by Member States (text and data mining for the purposes of scientific research, digital and cross-border teaching activities, preservation of cultural heritage).

 * References:

11. What does “public domain” mean?
From a literal point of view, the public domain indicates something that “belongs to everyone”. Although there is no legislative definition of public domain, it can be defined as the condition under which the work can be freely used by anyone, for any purpose (without prejudice to moral rights, at least for most civil law legal systems) without asking permission and without paying anything. The public domain, in this sense, represents the opposite situation to copyright, which normally grants the authors of the work exclusive rights over it. The legislator, in fact, has considered that in the balance between the author’s interest in the economic exploitation of the work and the public’s interest in access to culture, in some cases the latter should prevail.

Works in the public domain are:
 * 1) works that the legislator defines in the public domain since their first publication (e.g. laws, judgements, etc.);
 * 2) works whose terms of economic rights have expired;
 * 3) works that have been freely "dedicated to the public" by the authors.

12. Can I freely publish works on the web or are there any rules to respect?
The web is not exempt from the obligation to respect the law. If you publish work protected by Copyright law it is necessary to comply with the rules governing the proper use of them. The publication, therefore, will be free if (1) the work is in the public domain, (2) it falls within an exception or limitation provided by law, or (3) you have the permission of the rights holder (e.g. the work is released under Creative Commons license). By default, it’s not possible to publish a work without the permission of the rights holder. Publishing work with a mention of the author or the web site from which they are taken is not sufficient to avoid copyright infringement. For the sake of completeness, please note that the publication on a web site also requires you to respect all the rules involved in relation to the type of content (e.g. privacy policy).

13. What is an out-of-commerce work?
Out-of-commerce works are works that have never been in circulation, works no longer in circulation or not available through ordinary commercial channels. Out-of-commerce works are still protected by European Copyright law unless copyright has expired. Directive 2019/790/EU offers two mechanisms to allow cultural institutions holding out-of-commerce works to use them. Specifically, Member States shall provide that, under certain conditions, a collective management organisation (e.g. the societies or associations that manage collectively copyright performing and mechanical rights), in accordance with its mandates from rights holders, may conclude a non-exclusive licence for non-commercial purposes with a cultural heritage institution for the reproduction, distribution, communication to the public or making available to the public of out-of-commerce works or other subject matter that are permanently in the collection of the institution, irrespective of whether all rights holders covered by the licence have mandated the collective management organisation.

Alternatively, if no sufficiently representative collective management organisation exists, Member States shall provide for an exception or limitation to the rights, in order to allow cultural heritage institutions to make available, for non-commercial purposes, out-of-commerce works or other subject matter that are permanently in their collections, on condition that the name of the author or any other identifiable right-holder is indicated, unless this turns out to be impossible; and such works or other subject matter are made available on non-commercial websites.

 * Reference:

14. What is an orphan work?
Orphan works are works protected by Copyright law where the rights holders are unknown or very difficult or even impossible to trace. There are millions of orphan works in European libraries, museums, archives and public institutions. The British Library, which holds over 150 million volumes, estimates that orphan works make up about 40% of its collection. The information needed to identify the rights holders may be incomplete for a number of reasons, for example the work was published anonymously or under a pseudonym or is extremely dated and therefore the information has been lost. The Orphan Works European Directive, which came into force in 2012, has provided for a number of cases in which the orphan work may be used by cultural heritage institutions. For the purposes of establishing whether a work or phonogram is an orphan work, the legislation requires a diligent search in the Member State of first publication. The declaration of “orphan work” allows Member States to limit the exclusive right to reproduce and make available to the public for the benefit of cultural heritage institutions.

 * Reference:

15. Is copyright waivable?
Economic rights are subject to a limited term of protection and the rights holder can freely decide to renounce, transfer or license them to a third party in exchange for economic compensation or not. In some legislation, specific remuneration rights are not waivable. Moral rights don’t expire (and therefore they are imprescriptible) in many EU Member States, and are not waivable and/or transferable by the rights holder (e.g. excepted for the United Kingdom).


text: Category:Book:Author's Right, Copyright and Free Licenses for Culture on the Web


text:
Author's Right, Copyright and Free Licenses for Culture on the Web/Types of Content/Photographs

16. How many kinds of photographs exist?
Photography law finds its main source in the Berne Convention (which was modified, to include photographs, in 1948) which provides the “minimal” protection (in the sense of essential) of literary and artistic works and states that photographic works and other similar works must be considered artistic works. The Convention does not make a distinction between photographs as intellectual creations and photographs as mere representations of reality without requirements of originality and creativity. The choice whether to distinguish between different kinds of images has been left to the internal laws of each member state. In EU law, the possibility to provide for the protection to other kinds of images – in addition to the photographic ones – has also been left to the internal regulations of each member state by Directive 2006/116 (Protection of copyrights and certain related rights), which specified that all photographs that are original, ie. the result of the author’s intellectual creation, enjoy protection, without considering any other criteria besides “originality”.

Certain jurisdictions define various kinds of photographs:
 * 1) “Photographic works,” which have a creative “element” and enjoy the strongest protection under Copyright Law;
 * 2) “Simple photographs,” which are generally protected for a twenty year term (from the date of the production) and are images of “people or aspects, elements or facts of natural and social life, obtained by photographic or equivalent process”, and
 * 3) “Photographic reproductions” (i.e. “documentary” photos), which are mainly reproductions of documents, material items, technical drawings; they are protected under general principles of law (such as those of private law, in Civil law jurisdictions) rather than the Copyright Law.

 * References:

17. Which photographs are protected by copyright?
In general, photographic works enjoy full protection as artworks, the law grants to the author both moral and economic rights. In some jurisdictions, simple photographs (photographs without the so-called creative contribution, the personal imprint of the author, and which are mere reproductions) are protected under a related rights regime ; the law recognizes author exclusive rights of economic use, such as the right of reproduction, dissemination, sale, rights that allow the author to market, publish, and to display in exhibitions. With regards to reproductions, according to Directive 2019/790 (art. 14), Member States shall provide that, when the term of protection of a work of visual art has expired, any material resulting from the act of reproduction of that work is not subject to copyright or related rights, unless the material resulting from the act of reproduction is original, in the sense that it is the author’s own intellectual creation. In other words, “faithful” (non-creative) photographic reproductions works of visual art that are in the public domain through expiration of the term are not protectable by copyright.

 * Reference:

18. Does the law fix a minimum level of creativity in order to grant protection?
In order for a work to be protected at the European level, pursuant to Directive 2001/29 EC of 22 May 2001 (Infosoc Directive), it must be original, i.e. it shall be an intellectual creation of the author and shall be the expression of such creation. The Court of Justice has specified that copyright can only be applied with reference to original works. Emphasis is placed on the need to identify the personal touch of the photographer in the creation of the photograph and regardless of the artistic merit. In some jurisdictions, intellectual works of creative nature are protected, and there is no minimum level of creativity required. The works shall be the result of a creative activity and the photographer shall not have limited himself to reproduce reality, it is important that the author gives his own interpretation. Creativity is the author’s personal and individual expression. Therefore, the existence of a creative act, albeit minimal, is sufficient and the photographic work must be the result of a qualified activity of intellectual creation. The characteristics of creativity must be evaluated from time to time, the interpreter must consider both the choice and preparation of the photographer and the subjective element that is expressed in his representation of reality.

 * References:

19. Which are the rights of use connected to photographic works and to simple photos? How can they be transferred?
The rights of use generally referred to photographic works are:
 * 1) the right to publish it and to use it economically;
 * 2) the right of reproduction or multiplication in copies;
 * 3) the right of communication to the public;
 * 4) the right of distribution (i.e. marketing or in general of making available to the public by any means, whether for payment of a consideration or for free);
 * 5) the right to rent (assignment of use to any third parties) and to lend (assignment by institutions open to the public).

The above mentioned rights are transferable; in some jurisdictions the transfer requires a written contract and in its absence, it will be impossible to give evidence of the transfer.

In some jurisdictions, “simple” (non-original) photos are granted related rights, such as the exclusive right of reproduction, dissemination and sale. Such rights are transferable with a written contract or through the transfer of the negative or similar means of reproduction of the photograph (and for digital photographs, the “file”). The transfer of the negative may give rise to the presumption that a transfer of economic rights occurred, unless there is an agreement to the contrary.

To be noted that the transfer of the reproduction rights does not cause the transfer of the moral right of the photographer to be recognized as the author (right of attribution or paternity), which is a personal right and is generally not waivable.

20. Is one allowed to do a collage of photographs?
A collage implies the use/elaboration of someone else’s works or part of them. Therefore, for a collage, it will be necessary to ask for the authorization of the author (or rights holder) and to use the works within the limits of the rights of use which had been granted and to comply with the moral rights of the authors of the works included in the collage.

The consent of the author of the original works are necessary, as each one of them has exclusive right to use his work, or any derivative work (a collage could be derivative). The collage shall not cause prejudice to the original work. The author may oppose any deformation, cut or other modification and any act which damages the work, if it causes a prejudice to his honour and his reputation. The author may consent to a reproduction of his work, also partially, in derogation of his moral rights.

21. Is one allowed to modify an image without author’s consent?
The author has the exclusive right to modify the image, to combine it with another work, including disassembling the image’s elements and to transform it. The consent of the author is necessary if a third party wishes to modify it, save for some circumstances such as satire and parody. To qualify a work as parody, the image must evoke an existing work, while being noticeably different from it and constitute an expression of humour and mockery.

 * References:

22. Is the owner/custodian of an artwork also the holder of the author’s rights on the work, i.e. for photographic reproductions?
No, generally the custodian of the work is the owner and/or custodian, depending on the facts, of the work but he is not the rights holder, unless otherwise determined by contract. Therefore, it is necessary to specify in the agreement signed with the rights holder which rights are transferred to the purchaser and/or custodian (the sole right of custody, the right of custody and of exhibition, the right of reproduction, etc.).

23. Are there any cases of free use?
In some situations it is possible to reproduce a work without the consent of the author, whenever there is a general superior interest, social one, cultural and information one, and they prevail over the author’s right. The same principle applies to photographic works (right of information and news, the use of works for public safety reasons, or reproductions for personal use) and to simple photos (for education purposes, reproduction in scientific and educational works, or of public interest). The author has the right to a fair compensation. The catalogue of an exhibition is not a free use.

 * Reference:

24. Can one freely display the photographs?
At the European level, the need to be able to exhibit and promote artworks, for example part of a museum collection, is widely recognized among the exceptions and limitations provided by the author’s rights laws of he European countries, also in line with the provisions of Directive 2001/29/EC, art. 5(3)(j) which allows member States to provide for exceptions and limitations in order to advertise a public exhibition or sale of works, to promote the event, excluding any other commercial uses. The right to display – in favour of the owner/custodian – is not regulated in a harmonized manner in the various countries, as it is a right considered differently in the various legal systems: in the absence of a specific provision in such sense, cultural entities have become aware of the importance of negotiating the transfer of such rights, where possible, when they acquire such artworks.

 * Reference:

25. Who is the rights holder for the photographs commissioned and for those created by an employee of the museum?
Usually, for simple photos obtained during the performance of job tasks pursuant to a labour agreement, within the limits of the agreement itself, the exclusive right is held by the employer. The same principle applies when, in the event of commissioned photos (for example for photos done by a freelance photographer), and unless otherwise agreed, the photographed objects are owned/ or in custody by the commissioning party: if they are used commercially, a fair consideration is due to the photographer, but rights remain with the commissioning party owner of the objects.

26. Which technological measures can be used to protect digital photos?
Digital images travel, are shared at a great speed; often they are copied, downloaded, modified, even without the consent of the rights holder. To overcome these risks, there are technological measures, both to identify the right holder connected to the image and to prevent access or reproduction. The standard system is encryption which makes a text indecipherable unless the secret encrypted code, necessary to reveal the content, is known. One of the most common systems is the so-called digital watermark, which consists in the insertion, within the artwork, of a set of bits that modify the watermark of the digital code of the artwork. The digital logo may be visible to the eye or may not appear if not through a digital reading of the code of the work. There are also new software systems which, by providing a data registration service for the right holder, provide an online control service through specific programs aimed at finding the images used without the consent of the right-holders.

The DSM directive provides at article 7(2) that Member States have to ensure that users can access and use TPM-protected content according to some of the new mandatory exceptions. This also applies to content acquired by contract and made available across internet. The users have the right to require the right-holder to provide the technical means necessary to benefit from the exceptions and not to remove the TPMs by themselves. The exceptions considered are the one related to text and data mining for research purposes (art. 3), text and data mining in general (art. 4), educational one (art. 5), preservation (art. 6).

 * Reference:

27. Can photographs be considered cultural goods?
Yes, according to certain jurisdictions, such as the Italian one, photographs that meet the requirements of rarity and value can fall into the category of cultural heritage and as such are subject to the provision of the Code of Cultural Heritage. Both photographic works and simple photos can be protected by the cultural heritage provisions; the latter must be rare or have a valuable historical interest and they must be works by dead authors or whose creations date back over fifty years. For more recent photographs or photographs by living artists, no cultural heritage limits can apply. There are special categories of cultural heritage goods:
 * 1) photographs with related negatives and matrices, the production of which dates back over 25 years;
 * 2) collections of photographs, if they are of exceptional interest upon declaration of cultural interest;
 * 3) archives, if of particularly relevant historical interest and subject too declaration of cultural interest.

28. Are photographs considered to be cultural goods under specific controls and protections?
Cultural heritage photographs are subject to the obligation of conservation which must be carried out through a coherent, coordinated and planned activity of study, prevention, maintenance and restoration. The photographs cannot be moved from the place of conservation without the authorization of the relevant ministry, they cannot be used in contradiction to their historical or artistic character or in such a way that their conservation or integrity could be prejudiced. They can be subject to compulsory custody in order to guarantee their safety and prevent their deterioration. A right of inspection is granted to verify the state of conservation and custody.

29. Can they be freely transferred and can they be freely circulated?
No, as they are assets which may fall within the cultural property of the state; therefore, they may circulate within the limits and in compliance with specific provisions. In certain jurisdictions, if they are part of collections of museums, art galleries, galleries and libraries or archives, they cannot be transferred. The same principle may apply to images of living artists or which date more than fifty years if the works belong to state collections. The cultural heritage photographs that do not belong to the state or entities indicated can be transferred and the transfer document must be reported to the ministry, as the State may exercise a purchase pre-emption right. Loans for exhibitions and exhibitions must be authorised by the ministry even in the case of international circulation, for which a temporary circulation certificate is required.


text:
Author's Right, Copyright and Free Licenses for Culture on the Web/Types of Content/2D-3D Reproductions

30. What does reproduction mean?
The reproduction of a work consists in the creation of copies, direct or indirect, temporary or permanent, of the work, made in any form or manner.

 * Reference:

31. What does material deriving from an act of reproduction mean?
The material resulting from reproduction is everything that is the result of the act of reproduction itself and of the activity of making direct or indirect, temporary or permanent copies of the work, made in any form or way. The definition includes, for example, digital or analogical photographs of a work.

32. Is a 2D or 3D reproduction of a work of art subject to the copyright?
Yes, 2D and 3D reproductions of a work protected by copyright/author’s right law fall within the broader exclusive right of reproduction, and are subject to the rules referred to.

33. Is it possible to freely reproduce and re-use the material deriving from the reproduction of a work of visual or other kind of art in public domain?
The rights to the material resulting from the reproduction depend on the nature and characteristics of that material.

The possibility to freely use the material resulting from the reproduction of a work depends primarily on the type of protection of the work itself. Directive 790/2019 provides that, when the term of protection of a work of visual art has expired (i.e. when the work entered in the public domain), any material resulting from an act of reproduction of that work is not subject to copyright or related rights, unless the material resulting from that act of reproduction is original in the sense that it is the author's own intellectual creation.

 * Reference:

34. Can photographic reproductions of visual art works be commissioned?
Yes, it is possible to commission photographic reproductions of works protected by Copyright law, always respecting the copyright on the reproduced work (if any).

== 35. When a cultural institution commissions a digitisation project, is it the right holder on the final result of the digitisation only (images, rendering, graphic material) or also of the raw data (reliefs and points cloud)? Does it have to be provided for in the contract or agreement, or there is a legal presumption of it? == There is no explicit rule of law in this sense, therefore, the ownership of the raw data can only be established through the interpretation of the will of the parties as resulting from the contract.