Jump to content
3DCoat Forums

3DCoat for Linux initial setup (for reference)


Sorn
 Share

Recommended Posts

  • Contributor

Hi, here's a list of steps to set-up 3DCoat for Linux in a workstation for a single local user.

It may be useful to some, and as a reference to me. :)

  1. Download the latest Linux build (obviously)
    1. As of today, we can do this by going to https://pilgway.com/~sergyi/links-Linux.html
    2. Alternatively, we can download the last stable build in our ACCOUNT profile page at https://pilgway.com
  2. Unpack the file and place the resulting folder wherever we find it most appropriate.
    1. For the purpose of this list, I'd say I downloaded the file 3DCoat-2023.37.tar.bz2 in my downloads folder (/home/USERNAME/Downloads)
    2. In my file browser, I then extracted the contents of the file with right-click>'Extract Here' over the downloaded file.
      1. We can do that in a terminal or with a similar command in another file browser (using Gnome in this instance, with Files file browser) if we wish.
    3. It's quite a big file, it may take a little while to extract depending on our computer system.
    4. I finally get a folder called 3DCoat-2023.37 in my downloads folder (it's the folder extracted from the downloaded file, containing all files 3DCoat needs to start running).
  3. Rename the folder to 3DCoat-2023 (or whatever name we find practical, really, but I'll stick to that name in this little how-to).
  4. Move the folder 3DCoat-2023 to its final destination place if we wish, now.
    1. I've moved it to /home/USERNAME/Programs in my workstation (this is really not  necessary, but we'll need to remember the folder location anyway in an upcoming configuration step whether we move it or not, mind you).
  5. Create a text file called 3DCoat.sh in our home folder (/home/USERNAME/). (It can be anywhere, in fact, we just must remember where we place it for a future step).
    1. The text file should contain just two lines of text:
      1. cd /home/USERNAME/Programs/3DCoat-2023
        ./3dcoat-Ubuntu22.04

        This is the file that will actually run 3DCoat in our system: It goes to where the program executable is and runs it.
        Remember to change USERNAME in the lines above to our actual user name.

        (Since 2023 came about, 3DCoat has two versions for Linux: 3dcoat-Ubuntu22.04 and 3dcoat-Ubuntu20.04. In the example above I used the more recent one, but it can be changed by typing 3dcoat-Ubuntu20.04 instead in the text file if there are issues running 3DCoat in your machine to see if that helps.)

      2. Since this text file is meant to run as a script, a command, we must tell the system we authorise the text file to run as a program instead of treating it as an ordinary text file.
        We do it by right clicking the text file and in Properties tick "Allow executing file as program" in Permissions tab.
        Alternatively, with a terminal open in the directory (folder) where the file is, we type:
         

        sudo chmod +x 3DCoat.sh

         

  6. Create a .desktop file in /home/USERNAME/.local/share/applications called 3DCoat.desktop
    1. We can do it by using any text editor.
      A .desktop file is a Gnome Desktop Environment launcher for programs. Since 3DCoat will not be doing it on its own, we'll do it ourselves to have a nice way to run the program, with an icon, in our user's Desktop.
    2. The text file lines will be:
      1. [Desktop Entry]
        Encoding=UTF-8
        Version=1.0
        Type=Application
        Terminal=true
        Exec=/home/USERNAME/3DCoat.sh
        Name=3DCoat
        Icon=/home/USERNAME/Programs/3DCoat-2023/data/Icon/3DCoat.png
        Categories=Graphics;3DGraphics;
        StartupWMClass=3dcoat

        We must change USERNAME the above text lines to match our actual user name.
        Also, make sure that the icon folder description is correct too (if we placed our 3DCoat unpacked folder somewhere else, now is the time to edit that line to fit our folder structure).
        If, for some reason, we want 3DCoat to run without any output on a Terminal, we can change the line Terminal=true to Terminal=false in the text file 3DCoat.desktop

    3. The added StartupWMClass=3dcoat makes sure that when using a Dock panel in Gnome it won't duplicate visible icons when running 3DCoat (otherwise 3DCoat will appear as an additional icon in the dock when running, alongside the icon to launch it)
    4. We can create this text file anywhere and then move it to  /home/USERNAME/.local/share/applications afterwards.
    5. If we can't find the folder .local we can hit CTRL+h in our home folder file navigator window and it will show it, with other folders starting with a dot. Linux uses a dot at the beginning of a folder (or file) name to mark it as "hidden." Those are mostly configuration folders (and files) that a user hardly ever needs to see or touch manually. Hitting the shortcut CTRL+h once more will let all configuration folders hidden again; if we wish to tidy up the home folder appearance, that is.
  7. Restart the desktop or log out.
    1. Most times, after creating a desktop application launcher, we must "refresh" the desktop environment to make it available. We can do it like this:
      1. Reboot the system (a tad drastic but it will work for sure.)
      2. Log out. Then log in again. That restarts the desktop for the user.
      3. Press ALT+F2 hotkey shortcut and type r (just the letter R) and Return if a prompt appears. This sends the command "restart" to our desktop environment in most Linux distributions using Gnome.
  8. Run 3DCoat: Now we press the Super key (in many keyboards that key has a Microsoft Windows logo printed on it) and find the 3DCoat icon. We can just type it and it should show up. (Sometimes, depending on our Linux distribution, we may have to press SuperKey(the MS Windows logo one)+A or SuperKey+S to get to all the icons of the software installed).
    1. We can launch 3DCoat from here or pin it to a dock if we want the launching icon in the dock (if we use one) for convenience.
  9. Correct benign error messages appearing in the Terminal: As of today (version 2023.37 of 3DCoat for Linux) there are some png files' icc profiles in the 3DCoat folders that prompt a warning in an otherwise useful terminal output.
    They look like a lot, or many, "libpng warning: iCCP: known incorrect sRGB profile" messages.
    We can fix it by doing this:
    1. Open a terminal and go to where we placed the 3DCoat unpacked folder. (In my case, to /home/USERNAME/Programs/3DCoat-2023) and execute a command that will find any png file in any directory (folder) inside our 3DCoat folder and fix it.
      1. cd /home/USERNAME/Programs/3DCoat-2023
        find . -type f -name '*.png' -exec mogrify \{\} \;

        Next time we run 3DCoat it shouldn't complain about those sRGB profiles.
        Remember to change USERNAME in the lines above to our actual user name. Also, if the path (where the folder containing 3DCoat) is different, adjust it accordingly too.

  10. When a new build of 3DCoat is published, we can download the file and extract it over the current 3DCoat folder in /home/USERNAME/Programs/3DCoat-2023 (or wherever we placed it before).
    I just delete the folder and place the new one, renamed to just 3DCoat-2023 where the old was. In this way, I don't have to change any other file in the system, nor risking any old files that stays there as a leftover causing any trouble. Just to be practical and safe.
    If we don't want to rename the folder, and leave it as 3DCoat-2023.56 (as an example of a possible decompressed new build folder), or move the folder where the old one unpacked was, just remember to change the path in the 3DCoat.desktop and 3DCoat.sh text files with the new one.
    We can also repeat Step 9 for the new updated 3DCoat version.
  11. Licensing our 3DCoat build: I omitted the licensing prompt that appears the first time we run 3DCoat. It will only be asked the fist time we run 3DCoat with our user or until we actually load the license.
    1.  I just load the license downloaded from my account when prompted and that's it. We will not have to do it again after the first time, nor when a new version is installed like we did here, until it expires and we need to load a new one.
    2. 3DCoat creates some folders for us, with our user's preferences and settings in our user's Documents folder. Here, we've seen how to install the program in our user's Workstation. The configuration folders are left untouched. 

That's it for now.  Happy 3DCoating! :)
 

Edited by Sorn
Updated for 3DCoat 2023
  • Like 2
Link to comment
Share on other sites

  • Sorn changed the title to 3DCoat for Linux initial setup (for reference)
  • Contributor

Now for a system install. Instead of the per-user installation in the prior post.

  1. Download the latest Linux build (obviously).
    1. As of today, we can do this by going to https://pilgway.com/~sergyi/links-Linux.html
    2. Alternatively, we can download the last stable build in our ACCOUNT profile page at https://pilgway.com
  2. Create the folders in the system where we will unpack the 3DCoat file just downloaded in the prior step.
    1. sudo mkdir /opt/3DCoat && sudo mkdir /opt/3DCoat/3DCoat-2023

      This command will create a folder in /opt for 3DCoat and another called 3DCoat-2023 inside the first one.
      We will use the former to store the script that runs 3DCoat and the latter to store the program and its files and folders that comes with the file we downloaded before.

  3. Unpack the file downloaded in the folder created for it in the system.

    1. In a terminal, we move where we downloaded the file. In my case, that would be /home/USERNAME/Downloads

      cd Downloads

      This command will put us in the folder Downloads where we assume we downloaded the file from pilgway.com

    2. sudo tar -xvf 3DCoat-2023.37.tar.bz2 -C /opt/3DCoat/3DCoat-2023 --strip-components=1

      This command will unpack (decompress) the file downloaded (3DCoat-2023.37.tar.bz2 in this instance) in the directory (folder) we made for that purpose.

      Now, inside the file 3DCoat-2023.37.tar.bz2 there's a directory (folder) aptly named 3DCoat-2023.37 with everything inside.
      We could, yes, extract that directory into /opt/3DCoat and we would get /opt/3DCoat/3DCoat-2023.37
      The problem I see is that with every new version, we'd get a new folder added with the corresponding name version. In time, we'll have quite a lot of directories from all the versions installed.

      I suggest to have just the one 3DCoat version we are working with, the latest installed.

      For that purpose we made the 3DCoat-2023 folder inside /opt/3DCoat
      Now, we want to extract the contents of the 3DCoat-2023.37 directory that's inside 3DCoat-2023.37.tar.bz2 file WITHOUT creating the directory named with the version. We just want to extract all that's inside the file without the folder name.
      This is why I added --strip-components=1 in the terminal command above: it does just that. It skips the first folder of the compressed file and extracts from there where we told it to do so.
      As a result, we get all the file contents in /opt/3DCoat/3DCoat-2023

  4. Create 3DCoat.sh and 3DCoat.desktop text files (like we did for the single user workstation).
    This time, though, there will be some differences.

    1. 3DCoat.sh contents:

      1. cd /opt/3DCoat/3DCoat-2023
        ./3dcoat-Ubuntu22.04

        it now points to a different folder since our 3DCoat program is in a different place, obviously.
        This file script is the one that actually finds and starts 3DCoat.

        (Since 2023 came about, 3DCoat has two versions for Linux: 3dcoat-Ubuntu22.04 and 3dcoat-Ubuntu20.04. In the example above I used the more recent one, but it can be changed by typing 3dcoat-Ubuntu20.04 instead in the text file if there are issues running 3DCoat in your machine to see if that helps.)

      2. Since this text file is meant to run as a script, a command, we must tell the system we authorise the text file to run as a program instead of treating it as an ordinary text file.
        We do it by right clicking the text file with our file browser and in Properties tick "Allow executing file as program" in Permissions tab.
        Alternatively, with a terminal open in the directory (folder) where the file is, we type:
         

        sudo chmod +x 3DCoat.sh

         

    2. 3DCoat.desktop

      1. [Desktop Entry]
        Encoding=UTF-8
        Version=1.0
        Type=Application
        Terminal=true
        Exec=/opt/3DCoat/3DCoat.sh
        Name=3DCoat
        Icon=/opt/3DCoat/3DCoat-2023/data/Icon/3DCoat.png
        Categories=Graphics;3DGraphics;
        StartupWMClass=3dcoat

        Here we also changed the paths to match the 3DCoat's installation path in our system.
        This file is for the Gnome Desktop Environment, it creates a system launcher for 3DCoat, with an icon.

  5. Move or copy the two files where they belong:
    3DCoat.sh file must be in /opt/3DCoat
    3DCoat.desktop must be in /usr/share/applications

    Assuming we created the two files in our home folder, we should type, in a terminal:

    1. cd ~
      sudo cp 3DCoat.sh /opt/3DCoat && sudo cp 3DCoat.desktop /usr/share/applications

      The first command makes sure we are in our home directory where we created the two text files. [We can cd (Change Directroy) to wherever we created them, if not in the home directroy].
      The second command has two parts: it first copies 3DCoat.sh where it belongs and then puts 3DCoat.desktop where the  system stores all system-wide launchers. [We can change cp for mv in the command if we want to move the text files instead of copying them].
      In this way, we won't have to create either file again for every other user in the system.

  6. Correct benign error messages appearing in the Terminal: As of today (version 2023.37 of 3DCoat for Linux) there are some png files' icc profiles in the 3DCoat folders that prompt a warning in an otherwise useful terminal output.
    They look like a lot, or many, "libpng warning: iCCP: known incorrect sRGB profile" messages.
    We can fix it by doing this:
    1. cd /opt/3DCoat/3DCoat-2023
      sudo find . -type f -name '*.png' -exec mogrify \{\} \;
      The first command puts us where we installed (decompressed) 3DCoat. The second finds and fixes all png's in there.
       
    2. Next time we run 3DCoat it shouldn't complain about those sRGB profiles. Making the Terminal more useful and clean.
  7. Restart the Desktop
    1. Most times, after creating a desktop application launcher, we must "refresh" the desktop environment to make it available. Not sure we have to do it in this case, since we created a system launcher, but if we can't find 3DCoat launcher (icon), do this:
      1. Reboot the system (a tad drastic but it will work for sure).
      2. Log out and log back in again. That restarts the Desktop Environment for the user.
      3. Press ALT+F2 shortcut and type r (just the letter R) and Return if a prompt appears. This sends the command "restart" to our desktop environment in most Linux distributions using Gnome.
  8. Run 3DCoat as we launch any other program in our system. And pin it to a dock if we use one.
  9. Licensing our 3DCoat build: I omitted the licensing prompt that appears the first time we run 3DCoat. It will only be asked the fist time we run 3DCoat with our user or until we actually load the license.
    1. I just load the license downloaded from my account when prompted and that's it. We will not have to do it again after the first time, nor when a new version is installed like we did here, until it expires and we need to load a new one. Each user of the system will have to install its own licence, of course.
    2. 3DCoat creates some folders for us, with our user's preferences and settings in our user's Documents folder. The configuration folders are left untouched when we update 3DCoat in our system, and are, as stated, per user. Each user will have its own distinct 3DCoat configuration.
  10. Updating 3DCoat
    1. Once the new file is downloaded, we only repeat steps 3 and 6, that is: unpack and correct png's wrong profiles.
    2. We can, if we want, remove the contents of the previous installation before updating to the brand new build.
      1. This is a potentially dangerous command, so be careful and diligent when typing. Any potential loss from the misuse of this command will be on you. It erases all contents in a folder and everything that's under it. If you do that in a system folder you can seriously damage your installed system rendering it useless. If you point to some of your data directories you could lose your precious data. You have been warned!
        In a terminal, then, we can type, nervously:
        sudo rm -r /opt/3DCoat/3DCoat-2023/*

        Afterwards we can update 3DCoat as stated before: decompress and extract like in step 3 and remove the png's ICC errors like in step 6.

Happy 3DCoatting! :)

Edited by Sorn
Updated for 3DCoat 2023
Link to comment
Share on other sites

  • Contributor

Using 3DCoat with Blender with the Applink in Linux

  1. In Blender, enable the add-on 3D-Coat Applink included with it.
  2. In the Properties Editor>Scene Properties>3D-Coat Applink Settings>Folders:
    1. Set the Exchange folder to /home/USERNAME/Documents/3DCoat/Exchange
      Put your system user name instead of USERNAME in the line above.
    2. Do the same if you wish for the Object/Texture folder option.
  3. Select an object of your scene.
  4. in the Sidebar (Menu View>Sidebar or shortcut N) click the 3D-Coat vertical tab.
  5. Pick an option from the drop-down menu and click send.
  6. An error message with lots of scary words will appear and we will get sad.
  7. For safety, let's quit now Blender and 3DCoat.
  8. Open a File Browser on your Linux system, now.
  9. A folder named 3DC2Blender  has been created in your home folder.
    1. Right-click the folder and then left-click on Properties from the menu that should appear before you.
    2. In the Permissions tab, click on Change Permissions for Enclosed Files...
    3. Set Group Files Permissions to Read and Write
    4. Set Group Folders Permissions to Create and delete files
    5. Click the button labelled Change
    6. Close the Properties window
  10. Run Blender again, select an object of a scene, hit send button from the 3D-Coat panel in the Sidebar.
  11. Open 3DCoat and wait a bit until the message of incoming data from Blender pops up. It should now be working and we will feel happy.

This issue and fix was last tested using 3DCoat-2022.47 and Blender 3.4.0 Alpha build hash 4e7983e07320

Happy 3DCoating!

 

Edited by Allabulle
  • Like 1
Link to comment
Share on other sites

  • Carlosan pinned this topic
  • 1 month later...
  • 2 months later...
  • Advanced Member

Thanks for that walk-thru Allabulle. It works. I tend to just use MenuLibre to create my .desktop files. You can set the startup windowclass from there as well. As always there are multiple ways of doing things. For those that prefer a GUI to the terminal, this is a good option.

  • Like 1
Link to comment
Share on other sites

  • Contributor
Carlosan
This post was recognized by Carlosan!

Sorn was awarded the badge 'Great Content' and 1 points.

Guides updated for 3DCoat 2023, to avoid confusion and mentioning differences in the process since 2023 (two executables, none sharing the same name with prior versions of 3DCoat).

Happy 3DCoating! :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...