Difference between revisions of "User talk:Cboomf"

From WiiBrew
Jump to navigation Jump to search
m (Removed warning)
Line 70: Line 70:
 
}}
 
}}
 
Enjoy. --[[User:Lukegb|Lukegb]] 22:07, 5 August 2008 (CEST)
 
Enjoy. --[[User:Lukegb|Lukegb]] 22:07, 5 August 2008 (CEST)
 +
 +
== wiiwebserver, the story continues ==
 +
 +
Hi, I noticed that you have begun working on the server again.
 +
We should talk on IRC to redesign it. Just join #wiidev @ EFnet when you have time.--[[User:Henke37|henke37]] 20:37, 8 March 2009 (UTC)

Revision as of 22:37, 8 March 2009

Yay, my own page :-)

Coding

I am using the wii as a way to learn about C coding, the only other experience i have is in PHP, Pascal, HTML, VBScript, JavaScript or VB.NET ( yes i know, no comments please )

wii web server

I'd just like to let you know that the new branch have matured enough for you to also develop on it. Feel free to ask questions if my code is confusing somehow. Do note that my avalibility will be low the next week, I got a job. But I will still be online daily.--henke37 15:34, 24 July 2008 (CEST)

You ask why there is so many files, the answer is that my code is modular and easy to work with. And please, don't edit my user page, put it on the talk page instead ;). Also don't forget to sign when writing on my talk page. I think that this version is much better to work on since it's easy to edit and has well thought out algorithms instead of slowly aggregated code that happens to work. I think that if we work on it, we can get it up to the point of the old one within this week.--henke37 23:42, 24 July 2008 (CEST)

I chose c++ because I like how it works with object and due to it's extremely powerful standard template library (good luck finding a binary tree that can mostly be treated like an array indexed by text strings that is easy to use in C). As I stated before, I use more than one file because I want maintainability and easy access. Keeping too much in a single file (Yes, I am looking at you) just makes the file hard to use. It also helps the build time staying low since it only needs to recompile the changed stuff.

For your question about classes, I would recommend a C++ book or tutorial, but here it is in brief. Think of a C++ class as of a C struct. That's pretty much what they are, glorified structs. As you probably have noticed, these structs can have associated methods. It's pretty much the same thing as adding the struct name before the function name in C, just a shorter syntax. Of course classes got things like constructors and inheritance, but that's just lacing on the top, it's still glorified structs.

About your request to rewrite it in C, I have only one question, why? Why do you feel that we should throw away the existing code just to redo it in c? The cleaned up design would not change, it would just be slightly syntasticaly different. Again, I am happy to be the bridge from C to C++ for you. I mean, you wouldn't be the first person I help with programing.--henke37 11:32, 27 July 2008 (CEST)

I like your new idea, it is very nice, but it still needs a little improvement. I will rewrite code, upon request from you. That is, if you find some code you don't get, you tell me and I will try to rewrite that code as C. Here is generic methods as a starter:

c++:

Classname object;
object.method(parms);

c:

struct Classname object;
Classsname_method(&object,parms);

--henke37 19:41, 27 July 2008 (CEST)

Explanations

You ask a lot of questions, I better start replying to them

The double colon

The double colon, (::), is the scope resolution operator. It is used to access things that is in a different scope. For example Classname::method, it accesses the method in the class. As you might notice, it's used with this std thing, that's a namespace. Think of namespaces as folders where stuff is hidden from general view to not interfere with other stuff.

The run thing

The run method is simply the method that is run as a separate thread, think of it as another main function that runs at the same time as the main function.

The canvas

The canvas is a custom class I have written, it's an extension to the wiisprite library so that I can do runtime picture creation, you know draw lines and stuff like that. --henke37 09:28, 28 July 2008 (CEST)

libusbkbd

Hi

I have just seen that you have writen a lib to use the usb keyboard and i have writen one too.

It's a bit stupid don't you think so ?

I'm using directly the usb function whereas you must use /dev/usb/kdb.

It's my first contribution to the community so i don't know what is better to do.

You can contact me at davyg2 at gmail dot com

My library is there : http://wiibrew.org/wiki/Image:Libwiikeyboard-src.tar.bz2.

Bye

davyg

HomebrewPossiblyDangerous

Yay - you're the first one to use my brand-spanking new template! :D

For that I bestow:

Enjoy. --Lukegb 22:07, 5 August 2008 (CEST)

wiiwebserver, the story continues

Hi, I noticed that you have begun working on the server again. We should talk on IRC to redesign it. Just join #wiidev @ EFnet when you have time.--henke37 20:37, 8 March 2009 (UTC)