Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed typos #236

Merged
merged 1 commit into from
Aug 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions wiki/Backgrounds.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Background is a term in 2D graphics programming which refers to the image displa

## SNES Background Specs

SNES backgrounds are composed of tiled background. A tiled background consists of a collection of tiles and a map. Each tile has a number , so the map is the collection of numbers that are reprsented with the tiles.
SNES backgrounds are composed of tiled background. A tiled background consists of a collection of tiles and a map. Each tile has a number , so the map is the collection of numbers that are represented with the tiles.

A tile is a collection of 64 pixels forming a rectangle 8 pixels wide and 8 pixels tall. It is also possible to have 16x16 tiles but it is not implemented in PVSneslib for now.
A tile’s colors are defined by the tile’s color palette.
Expand Down Expand Up @@ -50,4 +50,4 @@ Backgrounds begin at x = 0 and y = 1. It is not a bug and it is linked to a tech
> Note that many games will set their vertical scroll values to -1 rather than 0.
> This is because the SNES loads OBJ data for each scanline during the previous scanline. The very first line, though, wouldn't have any OBJ data loaded! So the SNES doesn't actually output scanline 0, although it does everything to render it.

If you want more informations on it, you can consult [this page](https://wiki.superfamicom.org/backgrounds#toc-3)
If you want more information on it, you can consult [this page](https://wiki.superfamicom.org/backgrounds#toc-3)
2 changes: 1 addition & 1 deletion wiki/Community-FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,4 +370,4 @@ It is not a bug and it is linked to a technical constraint of the SNES:

> Note that many games will set their vertical scroll values to -1 rather than 0. This is because the SNES loads OBJ data for each scanline during the previous scanline. The very first line, though, wouldn't have any OBJ data loaded! So the SNES doesn't actually output scanline 0, although it does everything to render it.

If you want more informations on it, you can consult [this page.](https://wiki.superfamicom.org/backgrounds#toc-3)
If you want more information on it, you can consult [this page.](https://wiki.superfamicom.org/backgrounds#toc-3)
4 changes: 2 additions & 2 deletions wiki/Compiling-from-sources.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ Then, install [*brew*](https://brew.sh/):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
```

Finaly, install brew packages:
Finally, install brew packages:

```bash
brew install doxygen
Expand Down Expand Up @@ -253,7 +253,7 @@ Save the file and reload it:
source ~/.zshrc
```

Now `gnu-sed` will be used by default because it preceeds all other sed commands installed on your system.
Now `gnu-sed` will be used by default because it precedes all other sed commands installed on your system.

Congratulations, you're done to start to compile **PVSNESLIB** on *MacOS*!

Expand Down
12 changes: 6 additions & 6 deletions wiki/First-steps-with-No$sns-emulator.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ No$sns (pronounce it: No cash snes) is an emulator and debugger for Windows.
Like PVSnesLib full environment is currently for Windows system only, this one seems to be a good choice for its performances and capabilities.
Other emulators nearest hardware of Super Nintendo exist and you will have to try it but No$sns will be very useful during development of your project.

If you want more informations on it, you can consult [web site of developer](https://problemkaputt.de/sns.htm)
If you want more information on it, you can consult [web site of developer](https://problemkaputt.de/sns.htm)

# Configuration

If it is the first time you launch this software, the main window is the debugger : it contains hexadecimal informations on your rom.
If it is the first time you launch this software, the main window is the debugger : it contains hexadecimal information on your rom.
Go to "Options" tab, then "Emulation Setup" and configure keyboard or joypad buttons as you want. When you will finished it, do not forget to do "Options" then "Save Options".

PVSneslib has a function to help debug of your code : it use console to print informations. Depending the version of the software you use, you may have to enable it or adapt the value to your needs.
PVSneslib has a function to help debug of your code : it use console to print information. Depending the version of the software you use, you may have to enable it or adapt the value to your needs.

Go to "Options", "Debugger Setup" then update the hereunder value and save it :

Expand All @@ -22,7 +22,7 @@ For recent versions :

![configure debug messages](https://user-images.githubusercontent.com/48180545/214948543-f6ece2c0-db83-4c86-bab2-2315c05abe64.png)

To open this window, go to "Window" tab then "Debug Message Window". In your project, you can now print informations using `void consoleNocashMessage (const char *message)` defined in console.h file.
To open this window, go to "Window" tab then "Debug Message Window". In your project, you can now print information using `void consoleNocashMessage (const char *message)` defined in console.h file.
This function works like [standard printf function](https://en.wikipedia.org/wiki/Printf_format_string).

If you need a sample, take a look in "debug" example provided with PVSneslib.
Expand All @@ -37,7 +37,7 @@ The interface can be separate in 3 parts :
![Vram viewer interface](https://user-images.githubusercontent.com/48180545/56092240-bc24cd80-5eb9-11e9-9b31-8ef8675ea79f.png)

- Background tabs : each one which contain picture loaded. Their contents depends of background mode you used in your project because some of them doesn't exists if specific mode.
To get more informations on backgrounds, consult [the wiki page](https://github.com/alekmaul/pvsneslib/wiki/Backgrounds)
To get more information on backgrounds, consult [the wiki page](https://github.com/alekmaul/pvsneslib/wiki/Backgrounds)

- Tiles tab contains pictures you loaded for your projects. Memory is shared between each tab so if you load a 4bpp Picture, you will see chunk of it in other tabs.
But, do you know what is means bpp ?
Expand All @@ -47,4 +47,4 @@ bpp are Bits Per Pixels:
- 4 bpp means 2⁴ = 16 colors
- 8 bpp means 2⁸ = 256 colors

- OAM and palettes tabs : OAM is Object Attribute Memory where we store sprites informations and Palettes is the tab where you see color you use.
- OAM and palettes tabs : OAM is Object Attribute Memory where we store sprites information and Palettes is the tab where you see color you use.
4 changes: 2 additions & 2 deletions wiki/Input-and-Output.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ where :
* the last one is the address of graphics for font converted with gfx2snes

```
.. Somewhere where you initialized varables ...
.. Somewhere where you initialized variables ...
extern char snesfont;

//---------------------------------------------------------------------------------
Expand All @@ -41,7 +41,7 @@ extern char snesfont;

### Put text on screen

This is done with the **consoleDrawText** function, just call it with text coordonates and text value.
This is done with the **consoleDrawText** function, just call it with text coordinates and text value.
For example **consoleDrawText(5,10,"hello world")** to display at column **5**, row **10** the text **hello world **.

Also, you can format the string to display with generic format options :
Expand Down
6 changes: 3 additions & 3 deletions wiki/Installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ In the `MSYS2 UCRT64` terminal, update it:

Please remember that:

- Allways use **MSYS2 UCRT64** terminal windows to compile your code.
- Always use **MSYS2 UCRT64** terminal windows to compile your code.


#### Text editor
Expand All @@ -48,11 +48,11 @@ For convenience reasons, we recommend to use Visual Studio Code which is cross p
#### Emulator

A lot of emulators for the Super Nintendo SNES are available and the behaviour of your code can be different depending the one you use.
If you are on Windows, we directly recommend to use [no$snes](https://problemkaputt.de/sns.htm) which contains usefull functionalities.
If you are on Windows, we directly recommend to use [no$snes](https://problemkaputt.de/sns.htm) which contains useful functionalities.

Otherwise, you can use [Mesen](https://www.mesen.ca/) which is a high-accuracy emulator for Windows and Linux.

You can use any other emulator you want but in all cases, it is important to test you rom on different one which wich works as nearest possible than the real hardware.
You can use any other emulator you want but in all cases, it is important to test you rom on different one which which works as nearest possible than the real hardware.

### Installing PVSnesLib

Expand Down
6 changes: 3 additions & 3 deletions wiki/Roadmap.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ Feel free to help us by implementing any of this functionalities !
- add a function to remove comments in C source file (// ou /* */)
- add a function to detect include in C files then parse them
- manage implicit declaration of const array (const char a[] = {3,3}) on one or multiple lines
- solve the segmentation fault wich appears in tcc when using it without the -m32 flag (requirement to have 64b version). Try to apply these 2 updates manually to see if it works :
- solve the segmentation fault which appears in tcc when using it without the -m32 flag (requirement to have 64b version). Try to apply these 2 updates manually to see if it works :
- [cleanup: stop abuse of sym->c for #define tokenstreams](https://github.com/adorad/tcc/commit/bed17847bdfa872e219a12237e06df83e464bdba)
- [cleanup: stop abuse of sym->r for inline functions](https://github.com/adorad/tcc/commit/d0b432ab38b09cd167d8a8065ffe1e14878d6e2d?diff=split)
- manage LZ compression for graphics

# Medium priority:

- have only one credit list in readme.md, automaticaly injected in snes.h. Remove credit from wiki page
- have only one credit list in readme.md, automatically injected in snes.h. Remove credit from wiki page
- replace .obj files by .lib with wla dx
- Finish to implement mode 5, 6 by adapting gfx2snes to have compatible pictures (see [here](https://github.com/alekmaul/pvsneslib/issues/14))
- replace tasm.exe part (spc700) by the wla dx version to provide a unix alternative
Expand All @@ -41,7 +41,7 @@ Feel free to help us by implementing any of this functionalities !
- Manage hblank
- develop new driver to get more files format with sound engine
- update in pvsneslib sources, samples code and tools which use extern variables the data type (probably char) by the real type (u16 for map/sprites...). It will avoid some cast in the code will be more clear
- add new check on variable PVSNESLIB_DEBUG to provide detailed informations during the build process to assist users when they begin to use the library. For example: if you use setmode with mode7, display an error saying to use setmode7 function instead. It is a kind of assert which could be managed in asm with .FAIL directive. By default, the library could be built without this variable and it will not decrease performances
- add new check on variable PVSNESLIB_DEBUG to provide detailed information during the build process to assist users when they begin to use the library. For example: if you use setmode with mode7, display an error saying to use setmode7 function instead. It is a kind of assert which could be managed in asm with .FAIL directive. By default, the library could be built without this variable and it will not decrease performances
- Add mouse driver compatibility
- Add superscope compatibility
- Add all needed extensions for C/C++ and vscode (like Intellisense, etc ...) in wiki part of vscode template
Expand Down
2 changes: 1 addition & 1 deletion wiki/Tips-and-Bugs.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ What you can do is to set attribute((packed)) on all members of the struct to so

### Shiru's tips

Here are some others tips that [Shiru](http://shiru.untergrund.net/articles/programming_nes_games_in_c.htm) wrote about cc65 compiler but they can also aplied to 816-tcc compiler.
Here are some others tips that [Shiru](http://shiru.untergrund.net/articles/programming_nes_games_in_c.htm) wrote about cc65 compiler but they can also applied to 816-tcc compiler.
* Ordered List Item
* Avoid local variables as much as possible, make them static at least
* Avoid passing parameters to functions
Expand Down