Pages: 1 2 3 Next

Tag Archives: Linux

Pages: 1 2 3 Next

Tutorial: Stop-Motion in Linux

EDIT: Just been told there’s another way to do this using ffmpeg, I might add this in once I’ve had a play with it. Show ▼

This is just a quick post. It’s something I’ve always wanted to do, but never got round to it and minecraft was the best excuse to do it with. Video I made is embedded at the very end (or you can click here to watch it now: http://youtu.be/JdQxXj5czrU).

How I Made The “Frames”

Basically I took many screenshots in minecraft, roughly about 3-6 screenshots per section I wanted to show in the video, using the F2 key. I did this on my laptop using the “Play Offline” feature, and setting my server to allow anyone. So I showed up in game as “Player” and set him where I wanted the “camera”. I then logged into Minecraft on my workstation using my normal account. Then I began building, every so often taking 3-6 screenshots with the laptop.

How I Rendered The Images

Now obviously I’m going to assume before you started taking screenshots that you cleared out your previous minecraft screenshots folder (or webcam stills, whatever), and that your folder is full of images that you want to make into a video only. The screenshots folder is found at “/home/your_user/.minecraft/screenshots/” without quotes. Since these are terminal commands, you’ll need to “cd” to that folder when you want to render.

Step 1: Installing “mencoder”.

First you’ll need to install “mencoder” since this is what makes the initial video. This is found in most distros repos. I’m using Ubuntu 10.10, but should work for all. Do this with the following (you should be able to find it in the software centre too):

sudo apt-get install mencoder

Step 2: Creating a file with list of images.

Now we’re going to cd to the screenshots folder, and we’re going to make a file with a list of all the images in the correct order as stated by modified date/time. This is going to be used by mencoder so that it creates the stop-motion video. To make this file we’re going to do this:

ls -1tr > files.txt

You can name the file anything you want, in this example I’m using “files.txt”, however make sure you remember what file name you give it, and please note that’s a one (1) not a lower-case L. The -1 is so that each file is on its own line, t is to list by the modified time/date, and r is for reversing the order. Please check the man pages (command: man ls) if you want to use other options. I find this the best way to do it however.

Step 3: Render the video! \o/

Now that we have our file full of all the images we’re going to be using on each line (and in the correct order), we now need to finally render it into a video. Now I’m not going to go into details about the options I have picked, but it basically outputs into a raw video file (~200MB for a 1 minute long video) and is great for editing should you wish to do so. Anyways, on with the command line stuff!

mencoder -nosound -ovc copy -lavcopts vcodec=mpeg4 -mf fps=6 mf://@files.txt -o video.avi

The important thing to note by the way, is the -o option – this is to set the filename of the output. You can call this whatever you like, I just chose “video.avi”. Also note that vcodec is which codec we’re going to be using (in this case mpeg4), the -ovc copy is how I’m making this video output as raw video (basically a direct copy of the images), and one last thing I should mention is you’ll notice fps=6 – This basically defines what the framerate is, I set this to 6 because I was using ~6 images each time. However have a play with that number until you get the right results your after. Doing it this way takes less time, since it doesn’t have to process very much. Plus you get quality as good as the images your working with, which is perfect.

Step 4 (optional): Edit video, add sound.

You don’t have to do this, but well ~200MB is a bit much to upload to things like YouTube (plus it has no sound!). So I used PiTiVi Video Editing software that comes with ubuntu to import the video and song of my choice. And then rendered it how I liked it. I use MP4 Muxer with default options, because the size is decent at the end, and looks reasonable for the end quality (and works in YouTube).

That’s everything! We’ve just made a stop-motion video file! With that, I shall now present my first ever stop-motion video, using the medium of Minecraft! The song used is released under the Creative Commons licence (info in the video description), the pictures were designed by me (using popular ideas as a base), and the game used is Minecraft which is owned by Mojang. Enjoy!

VN:F [1.9.8_1114]
Rating: 0 (from 0 votes)

Video Tutorial: How to login/use IRC with empathy.

Now this is a quick video I made in one take on how to login to freenode IRC network using empathy. The video will be embedded at the bottom of this post. The video is found here, if your using a Feed Reader that doesn’t support embedded videos: http://www.youtube.com/watch?v=F_yvPl152L0

I’m using Empathy inside of Ubuntu 10.10 Meerkat Maverick, but should work on any distro that has Empathy.

If you need to add freenode to the list the details are:
address: irc.freenode.net
port: 6667

Alis is a channel list search bot. For a list of commands she accepts, type in “HELP” without quotes and she’ll tell you the commands she accepts. The example I used in the video are:
LIST *ubuntu*
LIST *programming*

Hope this helps some people out, if needs be I will quite happy redo the video if people think it is really bad. Any comments on something I may have missed feel free to post them here or on the YouTube video. Thanks.

Next blog post should hopefully have some irssi stuff, and how to split up conversations. Still need to do more fiddling with it before I do actually do a write-up about it though.

VN:F [1.9.8_1114]
Rating: 0 (from 2 votes)

New Idea For Ubuntu!

Just posted up an idea onto ubuntu brainstorm about how there should be a feedback button on the daily/alpha/beta builds of ubuntu. What do you guys think about it? Have a look at the link below for more information.



VN:F [1.9.8_1114]
Rating: 0 (from 0 votes)

Tutorial: Prettifying your terminal a bit…

I’ve always wondered how other distros have added cool little tweaks to the terminal so that it has quotes and other cool things. Now I know some of you may already know this, but I found it rather interesting… you can add commands to the end of .bashrc in your home directory so that it shows other things before your prompt.

Here’s what my terminal now looks like:
screenshot-hazrpgkoala

What You’ll Need

The packages you’ll need are fortune and cowsay. Fortune basically prints out a random quote, and cowsay basically shows you the character you can see in the screenshot. The default character in cowsay is, as the name suggests, a cow… however it does come with MANY different other characters with a default install. So lets first grab these applications. Open up a terminal and type in:

sudo apt-get install fortune cowsay

Testing They’ll Work

To test these are working, try the following commands:

1
2
3
fortune
cowsay hello world
fortune | cowsay -n -f tux.cow

There are many other cow files that you can use, and you can find them in /usr/share/cowsay/cows/. If you’d like to see a list of them try this command:

ls /usr/share/cowsay/cows/

Then change the tux.cow with one of those.

Editing Your .bashrc File

To add this effect to your terminal you simply need to add it to your .bashrc file in your home directory. Type in a new terminal the following:

nano .bashrc

Then simply add this at the end of the file:

fortune | cowsay -n -f tux.cow

Save the changes with CTRL+O then enter. Then close it with CTRL+X.

Or change the tux.cow with any of your choice.

Other Cool Tools

There’s another cool little tool you can use called “figlet”.

Here’s what it does:
screenshot-hazrpgkoala-1

To install it we do:

sudo apt-get install figlet

To use it you basically do:

figlet "message"

If you’ve like it to show up in cowsay, simply do:

figlet "message" | cowsay -n

Make sure you have the -n, otherwise it will show up wrong! If you’d like to add a different cow file simply add -f tux.cow (or any other cow file).

If you’d like to add it to your terminal, add it to the end of .bashrc as mentioned earlier. If you’d like to have both, then you can do so… just make sure you have them on separate lines.

Enjoy!

Enjoy, and hope you have fun using it. Feel free to send me a comment with cool little things you’ve done with yours, maybe even send in a screenshot to show us what you’ve done :).

VN:F [1.9.8_1114]
Rating: +1 (from 1 vote)

Tutorial: IPv6 Under Ubuntu 10.10

As some of you may know, I’m planning on updating my home server to an ubuntu-based one at some point, and I have been busy trying to get to grips with Linux and all its many different ways about how it works. Some of you may also know that IPv4 is slowly coming to an end; last I checked they’ve exhausted the pool of allocation for IPv4 (possibly bad choice of words? Please correct me if I’m wrong). I don’t mean that every possible combination of IP’s have been used up… they’ve just all been allocated off to individuals/ISP’s/corporations/etc. and its only a matter of time when they will no longer be able to provide people with an IP address (not without creating subnets, and NAT’s on top of each other to allow for more).

So in light of this, the lovely people at #ubuntu-uk have suggested I try and setup IPv6 tunnelled over IPv4 via one of many different IPv6 brokers… and I can honestly say I have successfully managed to do so! Not just for one machine, but for any machine that gets connected to my network! Score! \o/





Credits

Before I go on, as usual, I like to take this opportunity to thank the #ubuntu-uk community (mainly through IRC) for all their help and support. The main man himself that helped me through it is MartijnVdS, without his patience and help I think I would probably still be sat trying out millions of different combinations trying to get it to work. I can’t forget shauno, since me and him were talking about IPv6 (along with MartijnVdS and possibly a few others). Shauno has also helped when I was struggling by linking me to some useful places (when most people would normally be asleep). Thank you all :). If I’ve missed anyone out, please let me know.



I’m going to essentially walk through the settings and configuration as best as I possibly can (the way I understood it as people were trying to help me), and hopefully the information here will help others get started and setup too :).

Some info on World IPv6 Day is in the spoiler.
Show Spoiler ▼

Let’s begin…

Now there are two (2) ways you can get an IPv6. You can either set each machine individually, or you can setup a machine as an IPv6 router (or IPv6 announcer) to dish out IPv6 to all machines that are capable of doing so on your network. The second method is the way I have things setup at home, however as I was learning I did do the first method first. It is entirely up to you which one you want to do, and I will be listing them both. Just click on the section you’d like to follow.

Note: Both have similar steps. Also note, using a broker you’ll essentially be assigned 2^64 address (which is a HUGE number of IPv6′s that you can have for your devices!)

Show How To Setup Individually ▼

Show How To Setup as a Router ▼

Show Automatically Assign IPv6 ▼

Hope this guide helps you, and was informative at the same time. Please feel free to post any problems you may have in the comments, and I’ll try my best to answer them for you :).

VN:F [1.9.8_1114]
Rating: +2 (from 2 votes)
Pages: 1 2 3 Next
Powered by Google Talk Widget