I've written a report about t …

I’ve written a report about the Intersocs conference in Galway which happened over the weekend. Check it out below. If you were there and want to add anything, tell me and I’ll append it.

On Saturday 28th of November I made my way up to Galway in the west of Ireland for the Intersocs Ireland Conference ’98 that was taking place there.

I travelled from Cork with Owen “BLG” Kelly early on Saturday morning and just made it to National University of Ireland, Galway for the first lecture by Kenn Humborg which was delayed by almost an hour for some reason.

The lectures were in a theatre on-campus. The theatre holds a large screen (2×2 metres perhaps) which was used to present the lectures. It was really cool seeing an X display on such a huge screen! Especially seeing someone typing in an xterm, typing “ls”, “cd”, or typing “make” even!

Kenn went to a lot of work for his presentation. He created a set of slides using Magicpoint explaining some aspects of Linux networking, how IP masquerading works, how sendmail can be configured and he touched on related topics.

After a short break, the presentations continued with a talk by Joe Desbonnet about setting up Apache as a web server. Unfortunately Joe had been out the previous night so his talk was a small bit unprepared. He went over the configuration files Apache uses (httpd.conf, access.conf and srm.conf) and continued about using Perl and mod_perl. He spoke a little about the dangers of using mod_perl (memory leaks), how to combat those dangers (no sloppy coding, and the server kills threads every 150 hits), and the speed advantages of mod_perl.
He talked a little about the two HTTP protocols, 1.0 and 1.1, and telneted to port 80 of his own machine to demonstrate how a human could send commands to a web server.

A talk on HTML by Ken Guest followed this. It was presented in a browser of course, and links to related documents were included. Ken talked about different aspects of writing web pages by hand, and stressed the need for using compatible tags, hence, probably, his plain presentation which could have been viewed by any browser from Lynx upwards.
Ken shared some of the tricks he’s learned in creating web pages, such as putting a <BR> tag after text in a table in case the browser doesn’t understand tables or doesn’t interpret them well.

A public demonstration installing Linux was to take place soon afterwards but many of us went into Galway city center in search of refreshment. After burgers and drinks we walked around for a while before making our way back to the university for the aforementioned demonstration.
There were two machines, one had RedHat 5.2 on it and was at the stage where X was displayed on it, although the video card in the machine was unsupported by X and they had to resort to VGA.
The other machine was running Suse 5.3 which wasn’t as far advanced in the install, because XF86Setup defaulted to a refresh rate too low for the monitor.
The demonstration seemed to lose momentum before people in the audience started asking about applications for Linux. Several business men asked about desktop suites, to which many pointed out the excellent Star Office and Applixware as well as pointing out that Corel would be releasing it’s office suite very soon.
Alan Cox pointed out that Star Office was free for non-commercial use describing that concept as, “great!”, for trying out applications.
After that the discussion turned towards applications and became more informal as Kenn Humborg fetched his computer in and set it up with KDE and showed off the smart looking GUI on his machine. Ken showed off Klyx, and some of the configuration dialogues in KDE. I took over for a few minutes to show how simple it is to set up a printer on a RedHat system (using printtool) and went on to explain some of the benefits of using Linux.
At the same time people were walking around, talking in groups, or just sitting quietly. Alan Cox had quite a crowd around him within a few minutes. Unfortunately we were kicked out half an hour later at 7:30pm.

The “Great Nerd Table Quiz” took place later in the college bar where most people had drifted to by 8pm. I didn’t stay. I went for dinner with Owen and his brother at Pasta Paradiso which serves the most beautiful pizzas! If you’re in Galway make sure you try them!
In the end, the table with Ray Kelly, Sean McGrath, Joe Kilcullen and Kenn Humborg won the table quiz.

An ironic event occured when I tried to register at the hostel Ken Guest had booked.
They use cards with a magnetic strip to gain access to rooms in the hostel and they have to be swiped before you can use them. Unfortunately, mine didn’t work twice and I had to be registered again. I noticed they were using an MS Access database on their machine to register people and just when my details were to be entered the database crashed and had to be restarted..

Alan Cox

This was the guy a lot of guys came to see I think, at least judging by the crowds gathered around him most of the time! He took it all very well, chatting away and listening, “just like one of the lads”.

After the first 2 presentations he was introduced to us formally and a brief questions and answers session followed.
Topics discussed ranged from:

  • The development kernel (linux.org ran 2.1.129 for a day and a half before crashing, porn sites are the best sites to use to test the abilities of any new kernel.
  • GGI
  • speech recognition (emacspeak, Festival)
  • The structure of RedHat was asked about. RH has a marketing and sales department like most large companies! RHLabs was created because Mark wanted to get into real work again. In RHLabs they have lots of PCs and even a Nintendo!
  • Alan wasn’t going to be goaded into the whole QT/KDE vs Gnome battle. He believes the two desktops won’t merge as both groups want to work on their respective projects.
  • He’s payed to do kernel things 🙂
  • Kernel in CVS? Linus doesn’t want it to happen. A small number of people have to know what’s going on everywhere. They have to have a view of the whole kernel development. In CVS this would be too hard to do.
  • They might persuade Linus to use Jitterbug though.
  • Alan tries more patches than Linus does. That’s why you get the AC versions of some of the patches. Linus isn’t payed to do what he does. Alan is, so he can afford to work longer on the kernel and fix any bugs that might occur.
  • Mac floppies are _very_ difficult to support. Supposedly, Apple did everything they could in software, and anything else, well, they did that too.
  • When asked about the Corel Netwinder, Alan said the video, “wasn’t quite that fast”, and it had the performance of a Pentium. He talked about joining 15 of them together to make a very powerful computer, but nobody wanted to turn it on for fear of breaking anything!
  • Alan said that IBM are interested in PowerPC Linux.
  • Linux on the Xeon can address 2 gigs of memory. He knows things about Merced development he can’t tell anyone!

Related Links


Corrections:
(3-Dec-98) John Allen pointed out that it was Joe Desbonnet, and not Joe Desmond, who presented the talk on Apache. He also informed me that the Suse machine mentioned above was an old machine, and the refresh rate was too low for the monitor they selected in the setup.
(7-Dec-98) Kenn Humborg pointed out that I spelt his name wrong, and told me who won the table quiz.
(16-Dec-98) Ken Guest was the guy who demonstrated KLyx, not Kenn Humborg. He also emailed me links to the talks presented on the day.

4 Things: I'll post a report …

4 Things:
I’ll post a report about last weekend later on today. Good weekend. It’s something we’ll have to do again!
Deregulation of the telecom industry in Ireland occured today!! Telecom Eireann now have competition in the home/consumer market! Here’s hoping we get flat rate or free local calls!
If you live in Ireland, watch Techtv tonight on Network 2. It’s on just after 10pm (I think) and will have a short Linux report interviewing Owen (BLG) Kelly. I saw adverts for it on tv last night and they showed a logo I did in the GIMP for his web page!
Finally, I’m 23 today! Yep, getting older. I remember the days when we all coded in assembly and…

I'm off to Galway for the wee …

I’m off to Galway for the weekend. There’s going to be a gathering of Linux people at Galway University on Saturday morning, as well as a night out that night. Alan Cox should be going as well as most of the Linux guys in Ireland. Look for a report next week!
I got an interesting email during the week concerning real-time processes, and another subject upon which I’ll base a quizlet soon.27

I received an email from Tim N …

I received an email from Tim Newsome yesterday. He talked about giving a demo real time priority so it could execute smoothly. I would have agreed with him a few months back but I believe Linux is capable enough to handle the strain of a demo without resorting to giving it (the demo) complete access to the CPU. Hardware prices are dropping every day, and entry level machines are now much faster than the machine I work on at home(or at work..)
I want to see demos running on an X desktop. Maybe, with a slightly higher priority than other apps and it is possible.
Hey Tim! Wanna code a demo?

Something completely different now.
Recently I was on the receiving end of the evangelism of a highly sophisticated organisation wanting me to support it. I did too. I completely believed what I was told for 2 weeks. The organisation is Amway.
This is a company that will deliver products your door, at a cheaper price and promising a full money-back guarantee if you’re not satisfied with any product. There’s more to it than that, if you tell people about Amway and they buy goods, you get a small percentage bonus if they buy over a certain value of goods.
The problem is, the system is brain washing.

You’re encouraged to go check out Amway, but after hearing how good it is from the Amway representative and the fact that it is probably a friend who introduced you to Amway, many people will likely not check out Amway. I didn’t.
It was only after telling a friend, Dave, about the business that I checked up on it. He asked me questions about taxes and things I couldn’t answer. He brought up ideas that frightened me at the time. Do a search for the word Amway on Yahoo now and see some of the sites dedicated against Amway. They’re what I found.
I confronted my Amway “upline” with questions from Dave. He answered some of the questions well enough, and he did say that a company called “Donnagh & Bradstreet” would say that Amway are ok. I accepted this at the time.
The same evening I searched Yahoo for “Amway” and found out that “Donnagh & Bradstreet” are an acreditation firm. They’re guys who know if a company is a good bet to lend money to. Obviously I didn’t want to loan Amway money so their information would have been useless.
There’s also a list of steps to take to guarantee success in Amway. One is the system of motivational books and tapes. This isn’t an Amway thing, but organised by others. Later I remembered that on Will Smiths’ latest album there’s a guy who wants to do a business deal with Will, and promises him some of the proceeds of the motivational tapes and books..
They’re smart. I talked to a person I was told introduced Amway to Ireland, and the guy was a brilliant salesman. No, more than that. He had an answer for everything. One slip up though. He used Bill Gates as an example of a successful business man. To a non-computer person this might be encouraging but not to me. He described his business more eloguently in that sentance than at any other time.
I complained to him that a friend had tried a washing powder and wasn’t happy with it.
He asked me if I thought she was an expert in washing powders.
I replied, “No, but I’m sure her mother is.”
To which he replied, “Ah! But there’s plenty of mothers will buy it!” and smiled with a terrible grin.
As a learning experience, Amway can’t be beat. I learned more about myself and about human behaviour and motivation than I have in a long time.
Why is this relevant to Linux? Have you asked yourself why the GPL is the way to go when coding software? Have you looked at the Artistic Licence Perl is distributed under? Do you know the complete facts about something you’re advocating?

Demo Tutorial 2

Let’s get things moving shall we? In this tutorial I’m going to move that white dot we drew in the last tutorial around the screen!
The dot will follow coordinates generated by the sin and cos functions.

#include <math.h>
#include “ptc.h”

const SPEED=50;
const WIDTH=320;
const HEIGHT=200;

class Move_dot
{
  private:
    typedef struct count
    {
      int x;
      int y;
      int xdir;
      int ydir;
    } count;
    int32* sin_data;
    int32* cos_data;
    int frames;
    count current_pos;
    count last_pos;
    int dir;
    int last_counter;
  
    void update_counter (int* counter, int* dir)
    {
      if (dir[0] == 0) {
        if (counter[0] < 1024) {
          counter[0]++;
        } else {
          dir[0]=1;
        }
      } else {
        if (counter[0] > 0) {
          counter[0]–;
        } else {
          dir[0]=0;
        }
      }
    }
  public:
    Move_dot()
    {
      int index;
      sin_data = new int32[1024];
      cos_data = new int32[1024];
      for (float i=0; i < 360; i+=0.01) {
        index=(int)((i/360.0)*1024);
        sin_data[index]=(int)fabs(WIDTH*sin(i/-57.3));
        cos_data[index]=(int)fabs(HEIGHT*cos(i/-57.3));
      }
      frames=0;
      current_pos.x=150;
      current_pos.y=0;
      last_pos.x=150;
      last_pos.y=0;
      dir=0;
      last_counter=0;
    }

    ~Move_dot()
    {
      delete sin_data;
      delete cos_data;
    }

    void draw (int32 *buffer)
    {
        buffer[(int)((sin_data[last_pos.x])+(cos_data[last_pos.y]*WIDTH))]=0;
        buffer[(int)((sin_data[current_pos.x])+
          (cos_data[current_pos.y]*WIDTH))]=(255<<16)+(255<<8)+255;
        last_pos.x=current_pos.x;  
        last_pos.y=current_pos.y;  
        update_counter(&current_pos.x,&current_pos.xdir);
        update_counter(&current_pos.y,&current_pos.ydir);
        frames++;
    }
};
int main()
{
  try {
    int speed=SPEED;
    Move_dot move_dot;
The following is the Makefile you’ll use:

    // create format
    Format format(32,0x00FF0000,0x0000FF00,0x000000FF);

    // create console
    Console console;
    console.open(“tut02”,WIDTH,HEIGHT,format);

    // create surface
    Surface surface(WIDTH,HEIGHT,format);

    // loop until a key is pressed
    while (!console.key()) {

      if (speed == 0) {
        speed=SPEED;
        // lock surface
        int32 *buffer = (int32*) surface.lock();
  
        // draw dot
        move_dot.draw(buffer);
  
        // unlock surface
        surface.unlock();
  
        // copy to console
        surface.copy(console);
  
        // update console
        console.update();
      } else {
        speed–;
      }
    } // exit
    return 0;
  } catch (Error error) {
    // report error
    error.report();
  }
}

The following is the Makefile you’ll use:

# GNU Makefile for the X11 part of the PTC 2.0 C++ API
# Copyright (c) 1998 Christian Nentwich (brn@eleet.mcb.at)
# The PTC 2.0 C++ API is (c) 1998 Glenn Fiedler (ptc@gaffer.org)
# This package is licensed under the GNU LGPL
#
# Please refer to the file COPYING.LIB contained in the distribution for
# licensing conditions

include ../../Makefile.config

PROG1 = Tut02

all:  $(PROG1)

$(PROG1): $(PROG1).o
  $(CC) $(PROG1).o $(PTCLIB) $(PTC_X_LIBRARIES) -o $(PROG1)

.cc.o:
  $(CC) -c $(CFLAGS) $< clean:
  rm -f *.o

distclean:
  rm -f *.o
  rm -f $(PROG1)

Now compile Tut02.cc by typing make.
If you have previously compiled the example programs that came with PTC this should compile without problems.
Now run it from an xterm by typing:

./Tut02(return)
You should now see a window (or it will go fullscreen if your X server has such low resolutions) with a small white dot flying around it!
Press a key to escape out of the program.

How it works.

I’m not going to go back over the basic PTC stuff I covered in the previous tutorial. If you have any queries look at tutorial 1.

In my program I use 3 variables that never change. I defined these at the top of the program as constants:

const SPEED=50;
const WIDTH=320;
const HEIGHT=200;

The first constant, SPEED determines how often we refresh the screen. I have it set at 50 which works well on my machine. Change it and see what happens.
The last two figures should be self-explanatory. They are the width and height of the window we’ll create. These figures will also be used in generating our sin and cos values.
I used to wonder how I could code a demo in C++. “All those objects would get in the way”, I thought. Someone posted a message on CSIPD about a year or so ago voicing the same critisicm and among the replies was the idea that you put each demo part into a different class.
This is what I’ve done here. If I wanted to add a part to this small tutorial I would just code another class. With proper organisation I could create classes to do different functions of a demo part. Say, one class to move a scrolly and another class to draw and animate a logo or 3d object. All you would have to do is pass a pointer to the frame buffer to draw to!
“main” would probably take care of clearing the screen buffer at the end of each refresh, or another class could be called to record the changes to the frame buffer in-between calling each “action” class..
I’ve defined a Move_dot class here that contains all the code I need to draw and move my dot around the screen.
Inside the class I defined a struct to hold the details of the position of the dot as well as the direction (up or down) of the counter that runs through my sin and cos values. I also coded a small private function which either adds or subtracts 1 from the given counter and changes direction if necessary.
I decided to precalculate all my sin and cos values to speed up execution (precalc as much as possible!) and I needed two arrays to hold that data:

int32* sin_data;
int32* cos_data;

The class constructor, Move_dot(), creates my arrays for me, and fills the arrays with suitable values. It also defines various variables which I’ll use later on.
The class destructor, ~Move_dot(), on the other hand just deletes the two arrays freeing up the space they took.
The main function in the Move_dot class is the draw function.
It is called at every update to perform the animation on the white dot, and is the only public function in the class. It is called from the main loop of the program. It’s quite simple and should be easy to follow.

buffer[(int)((sin_data[last_pos.x])+(cos_data[last_pos.y]*WIDTH))]=0;

This line deletes the last drawn dot on the screen. We could just clear the whole buffer but this is much faster.

buffer[(int)((sin_data[current_pos.x])+(cos_data[current_pos.y]*WIDTH))]=(255< <16)+(255<<8)+255;

This line draws a white dot at some location on the screen.
The rest should be easy enough to decipher.
Mail me if you have problems.

Notes

Here’s a way to code demos in C++ which I touched upon above.
Code your demo parts as a series of classes. Each part should be contained in either one class or in a set of classes with suitable naming conventions.
i.e.

class part1_scroll
class part1_3dobj
class part1_music

class part2_vectors
class part2_dycp
class part2_music

If using the above you could set up PTC in “main” and create instances of each class and then call the draw function of each class. (or play of the music class.)
It’s probably advisable to let your “main” function clear the screen buffer after each refresh of video memory. Classes should just draw to the screen. They should not delete the previous image they drew (like my example above). This allows you to do nice things like implementing the “dirty rectangles” algorithm which just updates the parts of the screen which actually have been changed.
No, I’ve never done the above!

I've posted a new part in my …

I’ve posted a new part in my demo coding tutorial! Grab it at the Tutorial link on the side bar!

Check out the Linux Game Development Center. It’s a nice site with links to lots of tools, examples, projects and other nice game development stuff!

Update on Jan 1, 2008 linuxgames.org is gone. Grrr. It’s been taken over by a spammer.

On the day Slashdot links to m …

On the day Slashdot links to my page on Xoom the server decides to crash! Demonix is obviously now at lowrent.org. Now to stop all that spam from Xoom…
A new version of install-mail will be released soonish, but I guarantee nothing!
Check the “Linux Demo Ring” below. There are now 3 sites!
The PC Demo FanClub has moved yet again. Jer is also looking for people to provide content for his site. Click on “Join the Club” on his page for more details.

Have you ever tried to run dem …

Have you ever tried to run demos in dosemu or wine? I was thinking about creating a database of configurations required to run demos a few months back but I was sidetracked by exams and other such mundane happenings. Now I have the time and I was reminded about this by an email I received last night (It’s at home! Credits due when I get a chance!). I have some ambitious plans for a database that can be updated easily and daily with lists of working demos as well as configuration details.
Interested? Mail me at the address below!
On a seperate note, install-mail now has it’s own page. Check the side bar!

DemoNix may be moving shortly. …

DemoNix may be moving shortly. More news before it happens!
Bladeenc will be released in source form! It will be distributed under the LGPL. No news as to a release date at this time. The next version will hopefully have (among other features), STDIN/STDOUT support which will be very handy for all you script writers!
Check out Unload to turn your desktop into a MAC! It works quite well. Worth looking at!
New version of install-mail coming soon, as well as a page for it.
There’s been a plethora of music scene related tools coming out recently. There’s the GTK+ mod player mentioned in the last update as well as several other trackers and players appearing on freshmeat. Make sure your demo scene friends know about all these apps coming out!
I stumbled across the Triad homepage yesterday where I found two new demos by Triad for the C64! One is all about the Spice Girls while the other one looks _very_ similar to another demo, Red Storm, released by them a few years ago. Nice to see they’re still working on, and releasing C64 productions in 1998!
In preperation for the shutdown of Hornet, the PC Demo Fan Club has moved to a whole new site. No new demos mentioned though.