Announcement

Collapse
No announcement yet.

Usplash theme - Making of

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Usplash theme - Making of

    Warning

    This is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


    Usplash

    Package: libusplash-dev
    This package contains everything you need to make a usplash theme,
    including an example
    => /usr/share/doc/libusplash-dev/examples/README
    How to create usplash themes
    ============================

    Usplash in its current incarnation allows for simple and advanced themes. I'll
    start with explaining the basics of a theme and will introduce the more advanced
    topics later. I do assume that the reader has basic C programming knowledge and
    knows what a Makefile is for...

    > Usplash wiki
    > USplash, Ubuntu community
    > USplashCustomizationHowto
    > HOWTO: Change the default usplash colors
    > usplash transparency ?


    Usplash
    Usplash is a userspace application that uses the Linux framebuffer interface or direct vesa access to draw a splash screen at boot. It has a companion utility that is able to send commands to usplash, allowing information about the bootup sequence to be displayed in a more attractive way.
    What
    Usplash can show pictures and series of pictures (animation). Pictures are limited to the 256 color palette.

    Where and When
    Usplash is controlled by a c-language file.

    Hardware limits
    Available resolutions at the boot:
    Code:
    sudo hwinfo --framebuffer
    Here with my hardware:
    320x200, 320x240, 400x300, 512x384, 640x350, 640x400, 640x480. 800x600, 1024x768 and 1280x1024.
    Before you edit, BACKUP !

    Why there are dead links ?
    1. Thread: Please explain how to access old kubuntu forum posts
    2. Thread: Lost Information

    #2
    Re: Usplash theme - Making of

    Making a 256 color palette with the Gimp


    Making a new base palette picture (Base_palette.png)

    Image > Mode > Indexed > Generate optimum palette (maximum number of colors:256)

    Dialogs > Palettes (Right click Palettes) > Import Palette > Select Source (Image) > Import

    Now you should have a 256 color palette.


    Using that palette:

    Open a picture with the Gimp

    Image > Mode > Indexed -> Use custom palette / Your palette / Check that "Remove unused colors from colormap" is NOT on.


    With the non-english Kubuntu: Starting the Gimp with the command
    Code:
    LANGUAGE=en gimp
    helps a bit
    Attached Files
    Before you edit, BACKUP !

    Why there are dead links ?
    1. Thread: Please explain how to access old kubuntu forum posts
    2. Thread: Lost Information

    Comment


      #3
      Re: Usplash theme - Making of

      Configuration and commands


      Usplash configuration file: /etc/usplash.conf.
      # Usplash configuration file
      # These parameters will only apply after running update-initramfs.
      xres=1680
      yres=1050
      It is a text file so you can edit it by using a text editor. Afterwards you need to run
      Code:
      sudo update-initramfs -u
      or
      Code:
      sudo dpkg-reconfigure usplash
      man update-initramfs
      UPDATE-INITRAMFS(8) UPDATE-INITRAMFS(8)

      NAME
      update-initramfs - generate an initramfs image

      SYNOPSIS
      update-initramfs [-k version] [-c] [-u] [-t] [-v] [-b] [-h]

      DESCRIPTION
      The update-initramfs script manages your initramfs images on your local
      box. It keeps track of the existing initramfs archives in /boot.
      There are three modes of operation create, update or delete. You must
      at least specify one of those modes.

      man dpkg-reconfigure
      DPKG-RECONFIGURE(8) Debconf DPKG-RECONFIGURE(8)

      NAME
      dpkg-reconfigure - reconfigure an already installed package

      SYNOPSIS
      dpkg-reconfigure [options] packages

      Installed Usplash themes:
      Code:
      update-usplash-theme
      Here it tells:
      Installed themes:
      debian-theme
      usplash-theme-kubuntu
      kubuntu_pet_of_the_month
      kubuntu_throbber_and_spinner
      macx-splash
      usplash-theme-ichthux
      kubuntu_gauge_and_spinner
      Changing theme
      Code:
      sudo update-usplash-theme <theme name>

      If you get:
      update-alternatives: Cannot find alternative `/usr/lib/usplash/<theme name>.so'
      man update-alternatives
      update-alternatives(8) dpkg utilities update-alternatives(8)

      NAME
      update-alternatives - maintain symbolic links determining default com‐
      mands

      SYNOPSIS
      update-alternatives [options] command

      DESCRIPTION
      update-alternatives creates, removes, maintains and displays informa‐
      tion about the symbolic links comprising the Debian alternatives sys‐
      tem.

      It is possible for several programs fulfilling the same or similar
      functions to be installed on a single system at the same time. For
      example, many systems have several text editors installed at once.
      This gives choice to the users of a system, allowing each to use a dif‐
      ferent editor, if desired, but makes it difficult for a program to make
      a good choice for an editor to invoke if the user has not specified a
      particular preference.

      List of the usplash-artwork.so alternatives:
      Code:
      update-alternatives --list usplash-artwork.so
      Adding/updating alternatives:
      Code:
      sudo update-alternatives --install /usr/lib/usplash/usplash-artwork.so usplash-artwork.so /usr/lib/usplash/<theme name>.so 10

      Testing Usplash theme with the default resolution (usplash.conf):
      Code:
      sudo usplash -c
      or
      Code:
      sudo usplash -c -x 1024 -y 768
      man usplash
      usplash(8) usplash(8)

      NAME
      usplash - userspace bootsplash daemon

      SYNOPSIS
      usplash [-c] [-v] [-x num] [-y num]

      DESCRIPTION
      Uses the framebuffer to provide a graphical bootsplash screen from
      userspace during system boot and shutdown. As well as a static image,
      the screen includes a progress bar and text updated by commands
      received from usplash_write(8).

      OPTIONS
      -c Causes usplash to switch to a new console (vt8) before display‐
      ing the splash screen, rather than writing over the current one.
      Before you edit, BACKUP !

      Why there are dead links ?
      1. Thread: Please explain how to access old kubuntu forum posts
      2. Thread: Lost Information

      Comment


        #4
        Re: Usplash theme - Making of

        Example #1 Usplash with the standard throbber bar and a spinning kubuntu logo.

        Downloading package kubuntu-artwork-usplash from the Ubuntu Packages.

        Source Package: kubuntu-default-settings
        The following binary packages are built from this source package:

        kubuntu-artwork-usplash
        kubuntu artwork for usplash
        kubuntu-default-settings
        Default settings and artwork for the Kubuntu desktop
        => Downloading the latest version, at the moment it is:

        kubuntu-default-settings_8.04-20.dsc
        and
        kubuntu-default-settings_8.04-20.tar.gz

        In the same folder as dsc and tar.gz
        Code:
        dpkg-source -x kubuntu-default-settings_8.04-20.dsc
        man dpkg-source
        dpkg-source(1) dpkg utilities dpkg-source(1)

        NAME
        dpkg-source - Debian source package (.dsc) manipulation tool

        SYNOPSIS
        dpkg-source [options] command

        DESCRIPTION
        dpkg-source packs and unpacks Debian source archives.
        Usplash source-files are in the /kubuntu-default-settings-8.04/usplash/. There are:

        Picture files
        16 color palette
        throbber_back_16.png
        throbber_fore_16.png
        usplash_640_400.png
        256 color palette
        throbber_back.png
        throbber_fore.png
        usplash_640_480.png
        usplash_800_600.png
        usplash_1024_768.png
        usplash_1365_768.png
        usplash_1365_768_scaled.png (for 16:9 monitors)
        Bash and c-code:
        Makefile and usplash-theme-kubuntu.c


        Downloading source (usplash-macx-1.tar.gz) from the Gnome-Look: MacX Usplash Theme
        Description:
        This is my first attempt at a usplash theme. It uses custom animation to get the feel of a mac osx box booting - with the osx spinner. There are 4 different resolution images for use - 1024x768, 1280x1024, 1280x800, and 1440x900. Not sure about getting the widescreen resolutions to work but the 4:3 resolutions work. The default resolution is 1024x768.
        Unpacking -> /usplash-macx-1/, there is macx-splash.c.


        Using Kubuntu usplash theme and inserting there animation code from the MacX Usplash Theme.

        Removing 16 color files and picture files for the 16:9 monitors (i have 16:10 monitor) Making same changes in the usplash-theme-kubuntu.c and Makefile files.

        Taking spinner animation code from the macx-splash.c and inserting it to the usplash-theme-kubuntu.c.

        Making two simple animations: Kubuntu text animation (kubuntu_txt.gif) and spinning kubuntu logo (spinner.gif).

        A Moment of testing and finally: kubuntu_throbber_and_spinner theme

        Source (78 kB) >
        usplash_throbber_and_spinner-0.1.tar.gz
        or
        usplash_throbber_and_spinner-0.1.tar.gz


        Preview:
        Attached Files
        Before you edit, BACKUP !

        Why there are dead links ?
        1. Thread: Please explain how to access old kubuntu forum posts
        2. Thread: Lost Information

        Comment


          #5
          Re: Usplash theme - Making of

          Example #2 Usplash with a small gauge and a spinning kubuntu logo.

          Using same c-file as in the example #1 but removing throbber bar and using instead of small gauge (gauge.gif) with a numeric indicator.

          Source (82 kB) > usplash_gauge_and_spinner-0.1.tar.gz
          or
          usplash_gauge_and_spinner-0.1.tar.gz

          Preview:
          Attached Files
          Before you edit, BACKUP !

          Why there are dead links ?
          1. Thread: Please explain how to access old kubuntu forum posts
          2. Thread: Lost Information

          Comment


            #6
            Re: Usplash theme - Making of

            Example #3 Pet of the month theme.

            I have 16:10 monitor (1680x1050) and Usplash is using black wrappings/borders to fit a 4:3 picture (1024x768) to the 16:10 monitor.


            Downloading a picture from High Quality Nature & Landscape Desktop Wallpapers

            Scaling it to the 1024x768, indexing picture colors to the 256 and making a 256 color palette from the picture. That picture will be the background_1024_768.png.

            When used with the usplash.conf:

            # Usplash configuration file
            xres=1024
            yres=768
            The monitor will scale the 1024x768 picture back to the 1680x1050 and no more black borders !

            Source (302 kB) > usplash_pet-0.1.tar.gz
            or
            usplash_pet-0.1.tar.gz


            Preview:
            Attached Files
            Before you edit, BACKUP !

            Why there are dead links ?
            1. Thread: Please explain how to access old kubuntu forum posts
            2. Thread: Lost Information

            Comment


              #7
              Re: Usplash theme - Making of

              Installing and Uninstalling

              Bare Nessesities

              libusplash-dev
              Theming support files for usplash
              compiler, one way to install it is to use metapackage build-essential
              This package contains an informational list of packages which are
              considered essential for building Debian packages. This package also
              depends on the packages on that list, to make it easy to have the
              build-essential packages installed.

              If you have this package installed, you only need to install whatever
              a package specifies as its build-time dependencies to build the
              package.

              Installation example

              Unpacking usplash_pet-0.1.tar.gz and moving to the /usplash_pet-0.1/

              Compiling:
              Code:
              make
              make: Circular animation1.png <- animation1.png.c dependency dropped.
              pngtousplash animation1.png > animation1.png.c
              gcc -g -Wall -fPIC -o animation1.png.c.o -c animation1.png.c
              make: Circular background_1024_768.png <- background_1024_768.png.c dependency dropped.
              pngtousplash background_1024_768.png > background_1024_768.png.c
              gcc -g -Wall -fPIC -o background_1024_768.png.c.o -c background_1024_768.png.c
              make: Circular background_800_600.png <- background_800_600.png.c dependency dropped.
              pngtousplash background_800_600.png > background_800_600.png.c
              gcc -g -Wall -fPIC -o background_800_600.png.c.o -c background_800_600.png.c
              make: Circular background_640_480.png <- background_640_480.png.c dependency dropped.
              pngtousplash background_640_480.png > background_640_480.png.c
              gcc -g -Wall -fPIC -o background_640_480.png.c.o -c background_640_480.png.c
              gcc -g -Wall -fPIC -o kubuntu_pet_of_the_month.c.o -c kubuntu_pet_of_the_month.c
              make: Circular animation45.png <- animation45.png.c dependency dropped.
              pngtousplash animation45.png > animation45.png.c
              gcc -g -Wall -fPIC -o animation45.png.c.o -c animation45.png.c
              make: Circular animation6.png <- animation6.png.c dependency dropped.
              pngtousplash animation6.png > animation6.png.c
              gcc -g -Wall -fPIC -o animation6.png.c.o -c animation6.png.c
              gcc -g -Wall -fPIC -shared -o kubuntu_pet_of_the_month.so animation1.png.c.o background_1024_768.png.c.o background_800_600.png.c.o background_640_480.png.c.o kubuntu_pet_of_the_month.c.o animation45.png.c.o animation6.png.c.o
              rm background_800_600.png.c background_1024_768.png.c animation1.png.c animation45.png.c background_640_480.png.c animation6.png.c
              Installing:
              Code:
              sudo make install
              /usr/bin/install -c -d /usr/lib/usplash
              /usr/bin/install -c -m 755 kubuntu_pet_of_the_month.so /usr/lib/usplash/kubuntu_pet_of_the_month.so
              update-alternatives --remove usplash-artwork.so /usr/lib/usplash/kubuntu_pet_of_the_month.so
              update-alternatives --install /usr/lib/usplash/usplash-artwork.so usplash-artwork.so /usr/lib/usplash/kubuntu_pet_of_the_month.so 55
              update-initramfs -u
              update-initramfs: Generating /boot/initrd.img-2.6.24-19-generic
              Check #1
              Code:
              update-usplash-theme
              Installed themes:
              debian-theme
              usplash-theme-kubuntu
              kubuntu_pet_of_the_month
              kubuntu_throbber_and_spinner
              macx-splash
              usplash-theme-ichthux
              kubuntu_gauge_and_spinner
              Check #2
              Code:
              update-alternatives --list usplash-artwork.so
              /usr/lib/usplash/usplash-theme-kubuntu.so
              /usr/lib/usplash/kubuntu_throbber_and_spinner.so
              /usr/lib/usplash/kubuntu_gauge_and_spinner.so
              /usr/lib/usplash/debian-theme.so
              /usr/lib/usplash/usplash-theme-ichthux.so
              /usr/lib/usplash/macx-splash.so
              /usr/lib/usplash/kubuntu_pet_of_the_month.so

              Changing Usplash resolution:

              Alt + F2 and kdesudo kate /etc/usplash.conf
              # Usplash configuration file
              # These parameters will only apply after running update-initramfs.
              xres=1024
              yres=768
              and
              Code:
              sudo update-initramfs -u
              update-initramfs: Generating /boot/initrd.img-2.6.24-19-generic

              Changing Usplash theme:
              Code:
              sudo update-usplash-theme kubuntu_pet_of_the_month
              Using '/usr/lib/usplash/kubuntu_pet_of_the_month.so' to provide 'usplash-artwork.so'.
              update-initramfs: Generating /boot/initrd.img-2.6.24-19-generic


              Uninstallation example

              In the /usplash_pet-0.1/ directory
              Code:
              sudo make uninstall
              rm -f /usr/lib/usplash/kubuntu_pet_of_the_month.so
              update-alternatives --remove usplash-artwork.so /usr/lib/usplash/kubuntu_pet_of_the_month.so
              update-initramfs -u
              update-initramfs: Generating /boot/initrd.img-2.6.24-19-generic
              Check #1
              Code:
              update-usplash-theme
              Installed themes:
              debian-theme
              usplash-theme-kubuntu
              kubuntu_throbber_and_spinner
              macx-splash
              usplash-theme-ichthux
              kubuntu_gauge_and_spinner
              Check #2
              Code:
              update-alternatives --list usplash-artwork.so
              /usr/lib/usplash/usplash-theme-kubuntu.so
              /usr/lib/usplash/kubuntu_throbber_and_spinner.so
              /usr/lib/usplash/kubuntu_gauge_and_spinner.so
              /usr/lib/usplash/debian-theme.so
              /usr/lib/usplash/usplash-theme-ichthux.so
              /usr/lib/usplash/macx-splash.so

              Tested with the Kubuntu Gutsy Gibbon (7.10) and with the Kubuntu Hardy Heron (8.04.1). Everything seems to work but note that these are the first versions (0.1).
              Before you edit, BACKUP !

              Why there are dead links ?
              1. Thread: Please explain how to access old kubuntu forum posts
              2. Thread: Lost Information

              Comment


                #8
                Re: Usplash theme - Making of

                Wow!

                I have to lot to learn about usplash -- this helps! Thanks Rog!

                Comment


                  #9
                  Re: Usplash theme - Making of

                  Common usplash theme / Easy usplash theme

                  #1 Make a work directory

                  #2 Download:
                  • common-usplash-theme.c.txt (rename to common-usplash-theme.c)
                  • Makefile.txt (rename to Makefile)
                  • throbber_back.png
                  • throbber_fore.png



                  #3 Get a background image.
                  - http://www.kde-look.org/
                  - http://www.kubuntu-art.org/
                  - or somewhere

                  Here is a good one > Kubuntu Logo Wallpaper (Blue&Orange)

                  Using kubuntu_logo_wp_blue_1280x1024.jpg

                  Cropping it to the 1024x768 (background_1024_768.png) and scaling it to the 800x600 (background_800_600.png) and 640x480 (background_640_480.png).

                  Image files:
                  • background_1024_768.png
                  • background_800_600.png
                  • background_640_480.png
                  • throbber_fore.png
                  • throbber_back.png


                  #4 Make a 256 color palette file from the background_1024_768.png and use it to all image files.

                  #5 Compile
                  Code:
                  make
                  #6 Install
                  Code:
                  sudo make install
                  #7 Set the Usplash theme
                  Code:
                  sudo update-usplash-theme common-usplash-theme
                  Attached Files
                  Before you edit, BACKUP !

                  Why there are dead links ?
                  1. Thread: Please explain how to access old kubuntu forum posts
                  2. Thread: Lost Information

                  Comment


                    #10
                    Re: Usplash theme - Making of

                    Preview image and progress bar


                    Preview:
                    Attached Files
                    Before you edit, BACKUP !

                    Why there are dead links ?
                    1. Thread: Please explain how to access old kubuntu forum posts
                    2. Thread: Lost Information

                    Comment


                      #11
                      Re: Usplash theme - Making of

                      This is very nice work, thank you rog.

                      Now, to combine this with the gfxgrub-boot splash

                      As didble said, lots to do
                      HP Pavilion dv6 core i7 (Main)
                      4 GB Ram
                      Kubuntu 18.10

                      Comment

                      Working...
                      X