Commit Graph

137 Commits

Author SHA1 Message Date
be701b6278 Collada: Added support for ngon export/import and added triangulate option to export 2013-03-02 15:58:13 +00:00
4f3ca854e1 Fix various warnings with clang build, and adjust cmake clang warnings flags
to include a few more that gcc is using too.
2013-02-26 21:58:06 +00:00
20220d47e3 Dependency Graph: some refactoring which should have no user visible impact
besides performance in some cases.

* DAG_scene_sort is now removed and replaced by DAG_relations_tag_update in
  most cases. This will clear the dependency graph, and only rebuild it right
  before it's needed again when the scene is re-evaluated.

  This is done because DAG_scene_sort is slow when called many times from
  python operators. Further the scene argument is not needed because most
  operations can potentially affect more than the current scene.

* DAG_scene_relations_update will now rebuild the dependency graph if it's not
  there yet, and DAG_scene_relations_rebuild will force a rebuild for the rare
  cases that need it.

* Remove various places where ob->recalc was set manually. This should go
  through DAG_id_tag_update() in nearly all cases instead since this is now
  a fast operation. Also removed DAG_ids_flush_update that goes along with
  such manual tagging of ob->recalc.
2013-02-21 19:33:04 +00:00
7337c2d4c2 fix #34049: Collada importer doesn't import armature. Added some comments to the program code for better understanding. 2013-02-20 00:13:34 +00:00
134537b65b fix #34049: Collada importer doesn't import armature. Added support for 'rootless' armature similar to Maya. 2013-02-20 00:06:31 +00:00
ee64cbaf39 fix #34284 Collada: update problem for vertex weights directly after import. 2013-02-17 18:33:10 +00:00
8a20930c71 Collada: Fixed import of textures with path settings relative to main import file 2013-02-13 16:00:46 +00:00
3dfd736d45 Fix: Collada Import of armatures only added the root bone 2013-02-11 20:21:10 +00:00
22dbb675c1 Fix #33437 Collada: Added scale matching for Scene imports. 2013-02-10 22:14:56 +00:00
942ad6d9cd style cleanup 2013-02-10 17:06:05 +00:00
f34d1d5585 [#33437](partial fix) Collada: importing a scene changes units. Added an option to disable unit settings during import. 2013-02-09 16:19:30 +00:00
e3488af838 fixed: [#34080] import of COLLADA breaks on '#' in filepath 2013-02-09 00:23:59 +00:00
deeeaed3d8 [#33955] Collada Model Import Hangs Blender. Optimized Object import for better performance. Added logging messages 2013-02-08 19:52:02 +00:00
fdd18c7a07 fixed collada import for objects which have NO children 2013-02-08 12:23:36 +00:00
286d67b714 fix null pointer issue when child nodes reference to unknown/invalid mesh 2013-02-08 00:28:58 +00:00
9d02ac41dc Attempt to fix collada compilation after recent commit
I don't have recent collada compiled here atm, so perhaps there're
more issues here.
2013-02-05 13:04:01 +00:00
69993c5d40 style cleanup: spaces -> tabs 2013-02-04 00:18:09 +00:00
6baf63c83b Fix some warnings in the collade code, but did not fix two because they seem
to indicate bugs, left a comment about those.
2013-02-01 15:17:51 +00:00
c263753d17 Added gsoc-2012 collada improvements from bratwurst branch 2013-01-21 13:45:49 +00:00
08cea96ab0 Alpha premul pipeline cleanup
This assumptions are now made:
- Internally float buffers are always linear alpha-premul colors
- Readers should worry about delivering float buffers with that
  assumptions.
- There's an input image setting to say whether it's stored with
  straight/premul alpha on the disk.
- Byte buffers are now assumed have straight alpha, readers should
  deliver straight alpha.

Some implementation details:

- Removed scene's color unpremultiply setting, which was very
  much confusing and was wrong for default settings.
  Now all renderers assumes to deliver premultiplied alpha.

- IMB_buffer_byte_from_float will now linearize alpha when
  converting from buffer.

- Sequencer's effects were changed to assume bytes have got
  straight alpha. Most of effects will work with bytes still,
  however for glow it was more tricky to avoid data loss, so
  there's a commented out glow implementation which converts
  byte buffer to floats first, operates on floats and returns
  bytes back. It's slower and not sure if it should actually
  be used -- who're using glow on alpha anyway?

- Sequencer modifiers should also be working nice with straight
  bytes now.

- GLSL preview will predivide float textures to make nice shading,
  shading with byte textures worked nice (GLSL was assuming straight
  alpha).

- Blender Internal will set alpha=1 to the whole sky. The same
  happens in Cycles and there's no way to avoid this -- sky is
  neither straight nor premul and doesn't fit color pipeline well.

- Straight alpha mode for render result was also eliminated.

- Conversion to correct alpha need to be done before linearizing
  float buffer.

- TIFF will now load and save files with proper alpha mode setting
  in file meta data header.

- Remove Use Alpha from texture mapping and replaced with image
  datablock setting.

  Behaves much more predictable and clear from code point of view
  and solves possible regressions when non-premultiplied images were
  used as textures with ignoring alpha channel.
2012-12-31 13:52:13 +00:00
b867f9f17e style cleanup: comments & spelling 2012-11-18 01:22:31 +00:00
f3ece5a108 style cleanup: trailing tabs & expand some non prefix tabs into spaces. 2012-10-21 05:46:41 +00:00
d8144ef0f5 style cleanup: comment blocks 2012-10-04 13:26:15 +00:00
aa49ca25d5 incorrect spelling in comments 2012-09-26 20:05:38 +00:00
aaafa0c2fe code cleanup: move file string defines into BLI_path_utils.h, BKE_utildefines is now unused but keep incase we want to add defines there later. 2012-09-03 22:04:14 +00:00
192935eb04 fix:32348 Collada yfov to xfov conversion fo camera settings 2012-09-03 17:54:04 +00:00
10004d4a42 fixed: [#32240] Collada import when nodes share geometry but not material 2012-08-12 17:13:07 +00:00
aff4c781eb COLLADA: #29058 Fixed crash when illegal reference to non existing camera object is found. And report a warning to the console) 2012-08-05 10:23:34 +00:00
9090340175 COLLADA: fix for #32251. This seems to be compliant to the Collada 1.4.1 specification. 2012-08-04 22:18:56 +00:00
664c95d1eb code cleanup: collada
- when bubble sorting names - dont convert to str::string just to compare strings
- use BLI_linklist_index() to check if an item is in the list
- quiet some warnings
2012-06-16 09:16:24 +00:00
2e8a2f7668 style cleanup 2012-06-12 22:05:33 +00:00
36ed4818e5 patch #31794 Collada: make exporter more robust, now uses BKE_object_relational_superset() 2012-06-12 21:25:29 +00:00
1dccd4c98a code cleanup: naming - pose/armature/image
also use ..._find_name(..., name) rather then ..._find_named(..., name) --- both were used.
2012-05-05 16:03:57 +00:00
34b18fcbc1 code cleanup: BKE_ naming, also make bpy.data.images.load() always load a new image. (not use existing one) 2012-05-05 14:52:04 +00:00
299ff91ea1 code cleanup: BKE_scene api naming.
also stop numpy from being found in /usr/include with cmake.
2012-05-05 14:33:36 +00:00
a731e13043 code cleanup: function naming, use BKE_*type* prefix. 2012-05-05 14:03:12 +00:00
084fedd03a code cleanup: brush/camera naming 2012-05-05 00:58:22 +00:00
b075765edd Fix #31258: collada now selects newly added objects after import. 2012-05-03 21:32:49 +00:00
959a717d91 Fix #31250, #31248: wrong vertex normals after transform apply, collada import,
sculpt shape key switch. All cases that called this function needed parameter
only_face_normals set to false, so changed it now.

Also fixed wrong user count for imported mesh from collada and simplified
previous fix for tesselated faces to polygons conversion.
2012-05-02 23:36:34 +00:00
66581e903c Fix #31176: Collada model shows weird textures in editmode
Issue with multimaterial meshes and mface to mpoly conversion being before assignment of materials (which is done on meshobject instancing?).
Added explicit bmesh conversion to MeshImporter which is called from DocumentImporter::import.
2012-05-02 16:18:20 +00:00
6327c9aae1 style cleanup: whitespace, braces 2012-05-01 20:08:23 +00:00
Nathan Letwory
7cb037db86 Apply patch [#31179] COLLADA IMPORT instanced geometry improvement
from Martijn Berger

This patch improves importing instanced geometry consisting of multiple nodes.
2012-04-30 23:51:09 +00:00
e701f9b670 style cleanup: whitespace / commas 2012-04-29 15:47:02 +00:00
b340f930ec style cleanup: changes to brace placement / newlines - for/while/if/switch 2012-04-28 06:31:57 +00:00
5b88712ff9 move debug flag into its own global var (G.debug), split up debug options.
--debug
  --debug-ffmpeg
  --debug-python
  --debug-events
  --debug-wm

This makes debug output easier to read - event debug prints would flood output too much before.

For convenience:
  --debug-all turns all debug flags on (works as --debug did before).

also removed some redundant whitespace in debug prints and prefix some prints with __func__ to give some context.
2012-03-31 00:59:17 +00:00
07065b27b8 style cleanup 2012-03-28 05:03:24 +00:00
b8a71efeba style cleanup: follow style guide for/with/if spacing 2012-03-24 07:52:14 +00:00
ab4a2aaf4a style cleanup: follow style guide for formatting of if/for/while loops, and else if's 2012-03-24 06:38:07 +00:00
7ba12321ec #collada skeleton animation import, fixes #29246
Apply part of the patch #30070 by Juha Mäki-Kanto, that takes into account the transform of non-joint type parent in bone animation computation. Thanks!
2012-03-22 13:35:52 +00:00
8634d0e9c1 #collada instance_node import, partially fixes #27629
Patch applied in r37663 caused loss of <instance_node>s.

All parts of the smaller test file attached in the report now import.
2012-03-17 06:37:26 +00:00