Questions tagged [pythreejs]

Use this tag for questions related to pythreejs, the notebook extension based on Jupyter widgets.

18 questions
6
votes
2 answers

Embed widgets with pythreejs: wrong perspective and camera look-at

I am using pythreejs to visualize some 3D models. When visualizing the models on a Jupyter notebook, everything works as expected. But when trying to embed the widget in an HTML document, I am facing two problems: It seems the camera, on load, is…
Peque
  • 13,638
  • 11
  • 69
  • 105
2
votes
0 answers

Pythreejs Texture UV Mapping

I am not able to apply UV mapping to custom meshes in pythreejs. Here is what I am trying: import pythreejs material = pythreejs.MeshPhongMaterial( map=pythreejs.ImageTexture(imageUri="out/2ndAvePh_big.png") ) triangle_geometry =…
butterwagon
  • 479
  • 3
  • 9
2
votes
1 answer

ThreeJS cube not showing

I'm trying to learn ThreeJS, so I added the library to existing NextjS project. I wanted to see a cube in my frontpage. but I can't see nothing. The renderer code is : import React from 'react'; import * as THREE from…
jaaouani
  • 149
  • 1
  • 10
2
votes
0 answers

setting up pythreejs in JupyterLab

I'm setting up pythreejs on jupyter lab. Jupyter lab is setup using conda but there are issues with the pythreejs installation running on windows 7. >>> conda --version 4.6.14 >>> jupyter lab --version 0.32.1 >>> conda list pythreejs pythreejs,…
John---
  • 69
  • 1
  • 4
2
votes
1 answer

Self reflection in three.js

How to make a part of object visible in reflection on another part of the same object?
azer fghj
  • 21
  • 2
1
vote
0 answers

Why jupyter notebook or lab doesn't show an interactive pyvista scene?

I am unable to interact with pyvista plots either on jupyter notebook or lab. I am working on a geometric problem and want to check output of the code both in graphs and text (e.g., check vertex coordinates or face normals of a mesh). I get…
modinar
  • 13
  • 2
1
vote
0 answers

Photorealistic Rendering of 3D shapes Dynamically

I need some suggestion. I want a tool in which I can get Realistic Looking images of My 3D shapes. All 3D shapes are created runtime, are not FBX or any pre-existing 3D model. I have created 3D shapes…
1
vote
0 answers

Remove face by Index - three.js

I got a mesh based on a geometry of different faces. I'd like to remove a single face from this geometry during runtime. Is this possible using three.js? let mesh = new THREE.Mesh( geometry, textures ); mesh.name = "map" scene.add(mesh) //…
user11469699
0
votes
0 answers

Display glTF scenes in a Jupyter Notebook

I use Jupyter notebooks to teach fluid mechanics. It allows me to present students with various forms of media from basic python examples to videos and 3D models. https://github.com/nolankucd/MEEN20010 Currently I use pyGEL3D to display simple OBJ…
knolan
  • 21
  • 4
0
votes
0 answers

How to access the list of vertices and triangular faces in the following code?

I would like to basically know how do I access the list of vertices and triangular faces from the scene of gltf file. What I have currently is this. return from(fetch(targetUrl.toString(), { method: 'GET', headers: { …
Willow555
  • 13
  • 4
0
votes
0 answers

pythreejs, passing array of vectors into a shader

I need to pass an array of vectors as a uniform to a shader. As far as I understood code should be as follows: fragment_shader = """ uniform int myVectorSize; uniform vec4 myVector[50]; void main() { gl_FragColor = ... // using…
0
votes
1 answer

ThreeJS How to detect if any Box/Mesh collide with another?

I am really sorry if anyone already have asked this question, but I have tried to search a lot regarding this. Is there any method that can be use to detect if one Box in Threejs is colliding with one or many other objects in the scene? let…
USMANHEART
  • 93
  • 1
  • 9
0
votes
1 answer

Can't install and use properly pythreejs

I installed pythreejs following the instructions on the official website pip3 install pythreejs jupyter nbextension install --user --py pythreejs jupyter nbextension enable --user --py pythreejs Looking at the output of jupyter nbextension list,…
Gael Lorieul
  • 3,006
  • 4
  • 25
  • 50
0
votes
1 answer

How do I animate multiple objects simultaneously with each having a different KeyFrameTrack in pythreejs?

I generate the 4x4 transformation matrices over time for each object in a scene and use the VectorKeyframeTrack to set the transform matrix on a Mesh object. I am able to animate the objects individually with an AnimateAction for each object but…
moorepants
  • 1,813
  • 2
  • 22
  • 23
0
votes
0 answers

Three JS - make object tilt away from mouse on hover?

I’m trying to make a piece using three js where the object tilts away from the mouse on mouseover, like the locations here (mouse over the VIST tab): https://meowwolf.com/explore I don’t know whether this utilized three js or another library, but I…
blue
  • 7,175
  • 16
  • 81
  • 179
1
2