Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversion gets an USDZ without textures #643

Open
ghost opened this issue Oct 6, 2018 · 2 comments
Open

Conversion gets an USDZ without textures #643

ghost opened this issue Oct 6, 2018 · 2 comments

Comments

@ghost
Copy link

ghost commented Oct 6, 2018

Description of Issue

I first installed USD on a Debian distribution on AWS and I was able to convert my model to a USDZ model. But now I'm trying to do the same on an Amazon Linux 2 distribution and I can convert my model to a USDZ but it loses all the textures.

I might be missing something basic here. Any idea where I should start looking?

Steps to Reproduce

  1. Instal a basic AWS EC2 instance
  2. Execute this commands
sudo -i

echo 'export PATH="$PATH:/usr/local/bin"' >> ~/.bashrc
echo 'export PATH="$PATH:/usr/local/USD/bin"' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib"' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/USD/lib"' >> ~/.bashrc
echo 'export PYTHONPATH="/usr/local/USD/lib/python"' >> ~/.bashrc
source ~/.bashrc

# Dependencies
yum update
yum remove cmake
yum install git tree python-pip automake autoconf gcc-c++ zlib-devel qt-devel
# yum install libtiff-devel libpng-devel libjpeg-devel
# yum install libxml2-devel libxslt-devel qt-devel
# yum install gettext-devel gettext  gettext-libs flex-devel flex  bison-devel bison

# Download git sources
git clone https://github.com/glfw/glfw.git /usr/local/src/glfw
git clone https://github.com/PixarAnimationStudios/USD /usr/local/src/USD
git clone https://github.com/kcoley/gltf2usd.git /usr/local/gltf2usd

# gltf2usd
cd /usr/local/gltf2usd/ && pip install -r requirements.txt

# cmake 3.12.3
cd /usr/local/ && wget https://cmake.org/files/v3.12/cmake-3.12.3.tar.gz
tar -xvzf cmake-3.12.3.tar.gz && rm -rf cmake-3.12.3.tar.gz
cd /usr/local/cmake-3.12.3
./bootstrap
make
make install

# GLFW (for Imaging and USD Imaging)
cd /usr/local/src/glfw && mkdir build && cd build
cmake ..
cmake --build .
cmake --build . --target install

# Python dependencies
pip install pyopengl
pip install pyside

# USD
# add: `include <functional>` to: /usr/local/src/USD/pxr/imaging/lib/hd/renderThread.h
python /usr/local/src/USD/build_scripts/build_usd.py /usr/local/USD --python --ptex --openimageio

# Set workspaces
su ec2-user
mkdir  ~/workspace

# TEST
export REMOTE_SERVER="ec2-user@xxx.compute-1.amazonaws.com"                  # local
scp -i ~/.ssh/id_sayduck ~/samples/urag.zip $REMOTE_SERVER:~/workspace/                   # local
unzip ~/workspace/urag.zip -d ~/workspace/urag && cd ~/workspace/urag
python /usr/local/gltf2usd/Source/gltf2usd.py -g ./zzz-variant.gltf -o ./usdz/urag.usdz
scp -i ~/.ssh/id_sayduck $REMOTE_SERVER:~/workspace/urag/usdz/urag.usdz ~/samples/        # local

System Information (OS, Hardware)

  • AWS EC2 with the default AMI
@ghost ghost changed the title Model doesn't render textures Conversion gets an USDZ without textures Oct 6, 2018
@jtran56
Copy link

jtran56 commented Oct 9, 2018

Filed as internal issue #USD-4808.

@ghost
Copy link
Author

ghost commented Oct 11, 2018

Check this issue on gltf2usd repo for reference.

IT was due to the fact the paths where relative and not absolute.

AdamFelt pushed a commit to autodesk-forks/USD that referenced this issue Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant