blender

Convert 3D model to SceneJS JSON, including texture

ぐ巨炮叔叔 提交于 2019-12-03 07:36:30
问题 Motive I'm trying to create a small demo application using WebGL. I chose to use SceneJS, because it seemed an easy framework and would more than suffice for this purpose. I have downloaded a couple of .blend models (Amy Rose, amongst others) and exported them as a Collada (.dae) file using Blender. Then I used scenejs-pycollada to convert them to a json model. I just spent a couple of hours getting the scenejs-pycollada convertor to work. Apparently getting those Python dependencies to work

How can I access BPY in standard python console? BPY is the Blender-python -thing

不问归期 提交于 2019-12-03 06:00:46
问题 The author here in point 17.20-17.50 mentions that you can access BPY with the standard Python interpreter in the future. It is already 1 year old so how can I access the BPY with the standard python console? Trial 0: roundaround -solution not working with subprocess inside Blender subprocess.call(['vim', 'test.py']) # some editing of BPY -file with Vim (not working currently) subprocess.call(['python', 'test.py']) # trying to execute the python -file (not working currently) Trial 1: not

How to import Blender 3D animation to iPhone OpenGL ES?

时光怂恿深爱的人放手 提交于 2019-12-03 03:09:20
I am trying to do animations on iPhone using OpenGL ES. I am able to do the animation in Blender 3D software. I can export as a .obj file from Blender to OpenGL and it works on iPhone. But I am not able to export my animation work from Blender 3D to OpenGL. Can anyone please help me to solve this? If you have a look at this article by Jeff LaMarche , you'll find a blender script that will output a 3D model to a C header file. There's also a followup article that improves upon the aforementioned script. After you've run the script, it's as simple as including the header in your source, and

Camera walks through the wall built in blender

匿名 (未验证) 提交于 2019-12-03 02:38:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: My camera simply walks through interior walls of a house I built in Blender. Here are the steps I followed - Modelled a house in Blender. Applied physics -> collision to interior and the exterior walls of the house Exported as .obj and .mtl and used it in a-frame Placed the camera inside the house. While the camera is able to walk out of the house from inside by walking through walls, it is unable to move back into the house from outside as collision occurs. Also, camera is able to walk through all the interior walls of the house without

apply non-hierarchial transforms to hierarchial skeleton?

匿名 (未验证) 提交于 2019-12-03 02:31:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I use Blender3D, but the answer might not API-exclusive. I have some matrices I need to assign to PoseBones. The resulting pose looks fine when there is no bone hierarchy (parenting) and messed up when there is. I've uploaded an archive with sample blend of the rigged models, text animation importer and a test animation file here: http://www.2shared.com/file/5qUjmnIs/sample_files.html Import the animation by selecting an Armature and running the importer on "sba" file. Do this for both Armatures. This is how I assign the poses in the real

Static variable inheritance in Python

大城市里の小女人 提交于 2019-12-03 02:25:43
I'm writing Python scripts for Blender for a project, but I'm pretty new to the language. Something I am confused about is the usage of static variables. Here is the piece of code I am currently working on: class panelToggle(bpy.types.Operator): active = False def invoke(self, context, event): self.active = not self.active return{'FINISHED'} class OBJECT_OT_openConstraintPanel(panelToggle): bl_label = "openConstraintPanel" bl_idname = "openConstraintPanel" The idea is that the second class should inherit the active variable and the invoke method from the first, so that calling OBJECT_OT

THREE js imported OBJ model [.CommandBufferContext]RENDER WARNING: Render count or primcount is 0

匿名 (未验证) 提交于 2019-12-03 02:24:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I get thousands of errors (google chrome): [.CommandBufferContext]RENDER WARNING: Render count or primcount is 0. OBJ and MTL files exported from Bledner, using OBJMTLLoader.js as loader After moving to R73. Any experience? 回答1: This happens when the low level render call was told to draw zero vertices/faces. It is because you have one or more meshes with a polygon that has zero faces/vertices, so on each draw call this error piles up. The problem could be your model or it could be the export/import process. If it's the model, then below is

rendering and saving images through Blender python

这一生的挚爱 提交于 2019-12-03 02:20:38
问题 I am trying to render and save multiple images through python script in blender. I know how to render and save the image through the Blender GUI but I want to do it all through my script since I am using a set of nested loops and need to save multiple images. I am able to render the image and I guess save the image with the output being successful. But I am not sure where it saves to and when I try to edit the filepath it gives me the error of the context being incorrect. 回答1: Here's what I

Python script with arguments for command line Blender

匿名 (未验证) 提交于 2019-12-03 01:48:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm new to blender and python. I have a blender model (.blend) that I want to batch-render as several images providing some properties for each image. I wrote a python script with those parameters, something like: import bpy pi = 3.14159265 fov = 50 scene = bpy.data.scenes["Scene"] # Set render resolution scene.render.resolution_x = 480 scene.render.resolution_y = 359 # Set camera fov in degrees scene.camera.data.angle = fov*(pi/180.0) # Set camera rotation in euler angles scene.camera.rotation_mode = 'XYZ' scene.camera.rotation_euler[0] = 0

How to fix error when importing the blender module in Python

匿名 (未验证) 提交于 2019-12-03 01:41:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: i get the following error code when i import bpy into python is this because i need blender installed or can i solve this probelm another way' Color management: using fallback mode for management BLT_lang_init: 'locale' data path for translations not found, continuing AL lib: (EE) UpdateDeviceParams: Failed to set 44100hz, got 48000hz instead bpy: couldnt find 'scripts/modules', blender probably wont start. Freestyle: couldn't find 'scripts/freestyle/modules', Freestyle won't work properly. ModuleNotFoundError: No module named 'bpy_types'