GLX is used on Unix OpenGL implementation to manage interaction with the X Window System and to encode OpenGL onto the X protocol stream for remote rendering.
GLU stands for OpenGL Utility library. This is a set of functions to create texture mipmaps from a base image, map coordinates between screen and object space, and draw quadric surfaces and NURBS.
DRI stands for Direct Rendering Infrastructure. In simple terms, it enables hardware-accelerated 3D graphics on Linux. More specifically, it's a software architecture for coordinating the Linux kernel, X Window system, 3D graphics hardware and an OpenGL-based rendering engine.
(More http://www.opengl.org/resources/libraries/glx/)
Programming, Researching, Engineering, Employing and Analyzing of Troubleshootings. In addition, we study Usability - HCI - GUI - OpenGL - Project Management.
Saturday, August 29, 2009
Thursday, August 27, 2009
Draw in OpenGL
How to compile a program written in OpenGL
g++ -Wall -O my-program.cpp -lglut -o my-program
In which:
An introduction of GLUT (Understand easily)
Draw Text
Faster Text in OpenGL
Drawing Text
g++ -Wall -O my-program.cpp -lglut -o my-program
In which:
- -Wall: is a way of saying the compiler that it should output all the warnings
- -O: says the compiler to use some optimization techniques
- -l is a linker option stating to include the library followed the -l. Here is glut.
There is a little extra advantage when using GLUT, if you were developing an OpenGL application you should include the header files gl.h and glu.h (glu is the OpenGL Utility Library) but when you are including glut.h, glut.h guarantees the inclusion of gl.h and glu.h. So when we start and OpenGL application we start by writing:
#include
- -o: says the compiler that it should produce a binary file whose name is my-program
An introduction of GLUT (Understand easily)
Draw Text
Faster Text in OpenGL
Drawing Text
Tuesday, August 18, 2009
Download videos from YouTube.com in Linux
youtube-dl is a small command-line program to download videos from YouTube.com.
Install youtube-dl in Ubuntu
sudo aptitude install youtube-dl
This will complete the installation.
Using youtube-dl
Usage instructions are easy. Use youtube-dl followed by a video URL or identifier.
youtube-dl Example
youtube-dl “http://www.youtube.com/watch?v=foobar”
The video will be saved to the file foobar.flv in that example. As YouTube.com videos are in Flash Video format, their extension should be flv.Check this simple guide to convert .flv files to .mpg
More usage tips
You can change the file name of the video using the -o option, like in
youtube-dl -o vid.flv “http://www.youtube.com/watch?v=foobar”.
Some videos require an account to be downloaded, mostly because they’re flagged as mature content. You can pass the program a username and password for a YouTube.com account with the -u and -p options, like
youtube-dl -u myusername -p mypassword “http://www.youtube.com/watch?v=foobar”.
The account data can also be read from the user .netrc file by indicating the -n or --netrc option. The machine name is youtube in that case.
The simulate mode (activated with -s or --simulate) can be used to just get the real video URL and use it with a download manager if you prefer that option.
The quiet mode (activated with -q or --quiet) can be used to supress all output messages. This allows, in systems featuring /dev/stdout and other similar special files, outputting the video data to standard output in order to pipe it to another program without interferences.
The program can be told to simply print the final video URL to standard output using the -g or --get-url option.
Install youtube-dl in Ubuntu
sudo aptitude install youtube-dl
This will complete the installation.
Using youtube-dl
Usage instructions are easy. Use youtube-dl followed by a video URL or identifier.
youtube-dl Example
youtube-dl “http://www.youtube.com/watch?v=foobar”
The video will be saved to the file foobar.flv in that example. As YouTube.com videos are in Flash Video format, their extension should be flv.Check this simple guide to convert .flv files to .mpg
More usage tips
You can change the file name of the video using the -o option, like in
youtube-dl -o vid.flv “http://www.youtube.com/watch?v=foobar”.
Some videos require an account to be downloaded, mostly because they’re flagged as mature content. You can pass the program a username and password for a YouTube.com account with the -u and -p options, like
youtube-dl -u myusername -p mypassword “http://www.youtube.com/watch?v=foobar”.
The account data can also be read from the user .netrc file by indicating the -n or --netrc option. The machine name is youtube in that case.
The simulate mode (activated with -s or --simulate) can be used to just get the real video URL and use it with a download manager if you prefer that option.
The quiet mode (activated with -q or --quiet) can be used to supress all output messages. This allows, in systems featuring /dev/stdout and other similar special files, outputting the video data to standard output in order to pipe it to another program without interferences.
The program can be told to simply print the final video URL to standard output using the -g or --get-url option.
Labels:
Download video,
Linux,
YouTube
Saturday, August 15, 2009
Friday, August 14, 2009
Works have done in this week (10/08-14/08)
- Coded the Kosaraju's algorithm to find the strongly connected components
- Coded Graph's operations
- Understood the Becker's et al paper
A path with no repeated vertices is called a simple path, and cycle with no repeated vertices aside from the start/end vertex is a simple cycle. In modern graph theory, most often "simple" is implied; i.e., "cycle" means "simple cycle" and "path" means "simple path", but this convention is not always observed, especially in applied graph theory. Some authors (e.g. Bondy and Murty 1976) use the term "walk" for a path in which vertices or edges may be repeated, and reserve the term "path" for what is here called a simple path.
A path such that no graph edges connect two nonconsecutive path vertices is called an induced path.
A simple cycle that includes every vertex of the graph is known as a Hamiltonian cycle.
Wednesday, August 5, 2009
Research algorithms to optimize the placements
1. Find the longest cycle in the graph
* Sample Code: http://www.codeguru.com/cpp/cpp/algorithms/article.php/c5119
* Shortest Path Algorithms: http://www.umich.edu/~me558/manuals/LEDA/shortest_path.html
3. Detect a cycle in the graph
* Extending the shortest-path swarm algorithm to cycle detection: http://ieeexplore.ieee.org/Xplore/login.jsp?url=http%3A%2F%2Fieeexplore.ieee.org%2Fiel5%2F10622%2F33557%2F01594255.pdf%3Farnumber%3D1594255&authDecision=-203
- Depth First Search (DFS) (applying to find the cycle)
- Finding cycles in a directed graph (newsgroup and mailing list archives in the net)
- How to detect circle in a directed graph
- Finding all cycles in graph
- Best algorithm for detecting cycles in a directed graph
- Detecting cycles in directed graph
- Good way to find ALL cycles within a graph
- Strongly connected components
- Tarjan's strongly connected components algorithm
- Cycle detection
- Strongly connected components (Lecture notes)
* Sample Code: http://www.codeguru.com/cpp/cpp/algorithms/article.php/c5119
* Shortest Path Algorithms: http://www.umich.edu/~me558/manuals/LEDA/shortest_path.html
3. Detect a cycle in the graph
* Extending the shortest-path swarm algorithm to cycle detection: http://ieeexplore.ieee.org/Xplore/login.jsp?url=http%3A%2F%2Fieeexplore.ieee.org%2Fiel5%2F10622%2F33557%2F01594255.pdf%3Farnumber%3D1594255&authDecision=-203
Subscribe to:
Posts (Atom)