Giter Site home page Giter Site logo

c4d-plugin's Introduction

Sketchfab Cinema4D Plugin

Directly import and export models from and to Sketchfab in Cinema4D (R.20 or later)

Based on parsing code from Khronos Group - glTF-Blender-IO

Installation

First download the sketchfab-x-y-z.zip file attached to the latest release according to your O.S., and extract its content into a directory.

Note: Make sure to remove any previous installation of Sketchfab plugins. It is also recommended to rename the directory into "Sketchfab", as this will allow the plugin to be displayed under the name "Sketchfab" instead of "sketchfab-win-1.3.0" for instance.

To install the plugin, you should copy the newly extracted directory into an adequate directory, before restarting Cinema4D (you will find more information about plugin installation on the dedicated page of Maxon FAQ).

User Preferences directory

You can find your user preferences directory through the Open Preferences Folder in the Edit -> Preferences menu. From there, just copy the downloaded directory into the plugins folder (you might need to create it if it does not exist).

Custom directory

You can also install the plugin in a custom location. To do so, add the path containing the newly extracted directory to the search paths in the Edit -> Preferences -> Plugins menu.

Upon restarting Cinema 4D, the Sketchfab plugin should be available under the "Plugins" (R20) or "Extensions" (R21) menu:

menu

Login

The login process (mandatory to import or export models) should be straightforward: type in the email adress associated with your Sketchfab account as well as your password in the login form:

login

Your Sketchfab username should then be displayed upon successful login, and you will gain access to the full import and export capabilities of the addon.

Please note that your login credentials are stored in a temporary file on your local machine (to avoid repeating the login process multiple times). You can clear it by simply logging out of your Sketchfab account through the Log Out button.

Import a model from Sketchfab

Please note that all downloadable models are licensed under specific licenses: make sure to follow the different Creative Commons licensing schemes.

Once logged in into the Sketchfab Importer, you should be able to easily import any downloadable model from Sketchfab.

To do so, just run a search query and adapt the search filters:

Screenshot-1

Note that PRO users can use the My Models checkbox to import any published model from their own library (even the private ones).

You can navigate through the models available for download with the Previous and Next buttons, and inspect a model before importing it by selecting an icon:

Screenshot-2

Selecting the "Import Model" button will download the current asset and import it into your C4D scene

Screenshot-3

Please note that as Sketchfab models come from many different sources, the imported model might not be scaled correctly upon import: try rescaling it after having it selected in the hierarchy if you can see the object upon import !

Export a model to Sketchfab

Exporting should also be straightforward:

Once you have your scene file ready, open the Exporter and enter a title, description, and tags (separated by spaces) for your model. You can then choose to publish the model later with the "Draft" checkbox, and PRO users can also set their model as private, and optionally protect them with a password (here are more information about the different plans available on Sketchfab).

exporter

Hitting the Upload button will process your model, and a pop-up should appear upon success, with a link to the model on your Sketchfab profile.

Please note that although the uploading process can be quite fast (as it entirely depends upon your internet connection), the model will still need to process, and you will be available to monitor their status on the "Upload" tab of your profile:

Uploads

Known Issues

If none of the following description matches your problem, please feel free to report an issue.

Model has material using several UV layers

Mutli-UV models are not yet supported by this plugin, so models having these properties can look messed up.

Sketchfab <-> Cinema4D material conversion

Cinema4D and Sketchfab (glTF) are both using PBR materials but using two different models (different channels and material properties), which may lead to different material settings between Sketchfab and Cinema 4D.

In particular, metalness and roughness maps are not exported yet.

If you notice important differences, reporting the issue can help us investigate, and maybe find a way to solve the problem!

Vertex colors

Some models are using vertex colors, and this data is imported but not used by default. The reason is that vertex colors are exported for editing purpose but they are not always used for final render. In order to make Cinema4D use this data for a model, you need to edit its material(s) and enable both the COLOR channel and the Vertex Color layer in Reflectance channel. After this, vertex colors should be used for render.

Report an issue

If you feel like you've encountered a bug not listed in the known issues, or that the plugin lacks an important feature, you can contact us through Sketchfab's Help Center (or directly from the plugin through the Help -> Report an issue menu).

To help us track a possible error, please try to append the logs of Cinema4D Python console in your message (available in the Script -> Console menu for R20, or Extensions -> Console menu for R21).

Addon development

To prepare a development version of the plugin, you'll first have to clone this repository and update the Khronos glTF IO submodule:

git clone https://github.com/sketchfab/c4d-plugin.git
cd c4d-plugin/
git submodule update --init --recursive

You'll then need (only once) to patch the code from the Khronos submodule with the command:

./build.sh --patch

or (on Windows)

bash.exe build.sh --patch

The final releases can then be built by executing build.sh without arguments:

./build.sh

c4d-plugin's People

Contributors

aurl avatar cedricpinson avatar loicsketchfab avatar padrezippo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

c4d-plugin's Issues

2023 version

Hello,
Is there any possibility about 2023 version?

Thank you

Moving Animation from C4D to sketchfab is not working

I am trying to move an animated model from C4D to sketchfab. I have tried using the exporter and selecting include animation I have also tried using an FBX to export it and then upload it. In both cases it has not worked. Is there some sort of preliminary work I need to do like baking the animation before trying to upload it. Is there a way to export the animation as a separate file potentially and upload it along side the model.

Thank you for your help.

Sketchfab plugin not showing up in C4D 2023 - even after re-install

Traceback (most recent call last):
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\SketchfabPlugin.pyp", line 39, in
from sketchfab.ui_importer import *
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\ui_importer.py", line 33, in
import ui_login
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\ui_login.py", line 14, in
from api import SketchfabApi
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\api.py", line 20, in
from PIL import Image
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL\Image.py", line 114, in
from . import _imaging as core
ImportError:cannot import name 'imaging' from 'PIL' (C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL_init.py)
Traceback (most recent call last):
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\SketchfabPlugin.pyp", line 39, in
from sketchfab.ui_importer import *
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\ui_importer.py", line 33, in
import ui_login
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\ui_login.py", line 14, in
from api import SketchfabApi
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\api.py", line 20, in
from PIL import Image
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL\Image.py", line 114, in
from . import _imaging as core
ImportError:cannot import name 'imaging' from 'PIL' (C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL_init.py)
Traceback (most recent call last):
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\SketchfabPlugin.pyp", line 39, in
from sketchfab.ui_importer import *
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\ui_importer.py", line 33, in
import ui_login
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\ui_login.py", line 14, in
from api import SketchfabApi
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\api.py", line 20, in
from PIL import Image
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL\Image.py", line 114, in
from . import _imaging as core
ImportError:cannot import name 'imaging' from 'PIL' (C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL_init.py)
Traceback (most recent call last):
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\SketchfabPlugin.pyp", line 39, in
from sketchfab.ui_importer import *
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\sketchfab\ui_importer.py", line 33, in
import ui_login
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\ui_login.py", line 14, in
from api import SketchfabApi
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\sketchfab-win-1.5.0\sketchfab\api.py", line 20, in
from PIL import Image
File "C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL\Image.py", line 114, in
from . import _imaging as core
ImportError:cannot import name 'imaging' from 'PIL' (C:\Program Files\Maxon Cinema 4D 2023\plugins\SketchFab\Sketchfab\dependencies\PIL_init.py)

does not display in s22 mac / catalina

Running Cinema4D S22 in OSX Catalina - installed plugin to default plugins directory as well as specifying a custom search path, restarted, nothing displays in the Extensions menu, nor the extensions > plugin manager directory.

Visibility not exported

I am animating the two 'visible in editor' and 'visible in render' options to hide objects, however these changes do not show up in sketchfab. Reading up, it seems visibility animations are supported by other DCC apps. IS this a bug or is there some other way to officially hide objects in animations?

plus a small general question in case anyone can help, is it possible to overwrite/reupload to a project from the c4d plugin? eg. I export a file to sketchfab, apply all my material and light updates, but then need to make a change in c4d, can I keep my changes I have made in sketchfab? It is possible with file uploads but I cannot make the c4d exporter update an existing sketchfab project.

Does not load in C4D R23 macOS Big Sur M1 chip

Hi sketchfab team, the plugin doesn't load in my M1 Mac Mini.

Here is the logs of the errors :

Traceback (most recent call last):
  File "/Applications/Maxon Cinema 4D R23/plugin/sceneupdater/sceneupdater.pyp", line 13, in <module>
import base64 as b, types as t, zlib as z; m=t.ModuleType('localimport'); blob=b'\
ImportError:dlopen(/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so, 2): no suitable image found.  Did find:
	/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so: mach-o, but wrong architecture
	/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so: mach-o, but wrong architecture
Traceback (most recent call last):
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/SketchfabPlugin.pyp", line 39, in <module>
from sketchfab.ui_importer import *
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/sketchfab/ui_importer.py", line 33, in <module>
import ui_login
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/sketchfab/ui_login.py", line 14, in <module>
from api    import SketchfabApi
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/sketchfab/api.py", line 17, in <module>
import requests
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/dependencies/requests/__init__.py", line 43, in <module>
import urllib3
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/dependencies/urllib3/__init__.py", line 8, in <module>
from .connectionpool import (
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/dependencies/urllib3/connectionpool.py", line 36, in <module>
from .response import HTTPResponse
  File "/Applications/Maxon Cinema 4D R23/plugin/sketchfab/dependencies/urllib3/response.py", line 3, in <module>
import zlib
ImportError:dlopen(/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so, 2): no suitable image found.  Did find:
	/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so: mach-o, but wrong architecture
	/Applications/Maxon Cinema 4D R23/resource/modules/python/libs/python37.macos.framework/lib/python3.7/lib-dynload/zlib.cpython-37-darwin.so: mach-o, but wrong architecture
>>> 

How to install on MAC OSX?

Usually pretty good at this but after a few hours and many attempts I need to reach out for help or possibly highlight a bug/issue.

I want to make sure this works before paying so I am using the trial of Cinema 4D, 25, and trying to integrate with a SketchFab Pro account.

Essentially it seems like the installation process is unclear. So I tried extracting, renaming, and placing the plugin file in about every folder that seemed relevant. Restarting, logging in, logging out, trying new version of Cinema 4D, etc. Nothing worked.

Any ideas on how I can fix this? Is this the right folder path, correct folder name, do I need to install anything else or enable anything? Looked all over the program and couldn't find anything related to SketchFab...

Please see screenshots. Happy to do anything to try and get this to work. Thank you!

Screen Shot 2022-06-07 at 2 41 20 PM

Screen Shot 2022-06-07 at 2 41 40 PM

Screen Shot 2022-06-07 at 2 41 06 PM

Screen Shot 2022-06-07 at 2 40 56 PM

Screen Shot 2022-06-07 at 2 40 16 PM

Not able to login in from C4d R25

After inputting my credentials, tapping the login button does nothing. This happens on both the import and export sections of the plugin.

Suddenly cannot access my own models C4D r22?

Hi!

I've been using the sketchfab plugin now for weeks and it's performed perfectly. Now a couple of days ago I noticed that I cannot download my own models anymore. Not happens when I click them. This is not an issue with the other models, like the staff picks for example. They all work perfectly.

I've tried reinstalling cinema, tried an older version of cinema. As well as on a different computer. It's the same issue. Might it have something to do with my Sketchfab account?

Ps. As mentioned in the title I'm using C4D r22 and I'm on sketchfab 1.3.1.

Cheers,
Lewis

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.