Collada Import Ignores Vertex Normals #49814

Closed
opened 2016-10-22 05:35:27 +02:00 by Lukas Siemon · 17 comments

Blender seems to be ignoring vertex normals when importing COLLADA the way I'm defining them.

I'm the developer of a voxel editor called VoxelShop. A simple file containing only a cube would look as following.

(NOTE) Sample File: **http:*pastebin.com/uEgxTrTw***Excerpt://

<?xml version="1.0" encoding="UTF-8"?>
<COLLADA xmlns="http://www.collada.org/2005/11/COLLADASchema" version="1.4.1">

...
<library_geometries>


...




...



</library_geometries>
...

</COLLADA>

This imports correctly into http:*www.open3mod.com/ and validates against the https:*www.khronos.org/files/collada_schema_1_4_1.xsd . However,

(WARNING) Blender ignores the vertex normals when importing.

Excluding the normals altogether from the COLLADA file results in the same normals being generated. This leads me to believe that they are simply ignored.

I tried looking at the blender code here, but couldn't really find where the relevant part of the xml is processed.

Any insight would be appreciated!

Blender seems to be ignoring vertex normals when importing COLLADA the way I'm defining them. I'm the developer of a voxel editor called [VoxelShop](https://blackflux.com/node/11). A simple file containing only a cube would look as following. (NOTE) **Sample File:** **[[http:*pastebin.com/uEgxTrTw]]***Excerpt:// ```lang=xml <?xml version="1.0" encoding="UTF-8"?> <COLLADA xmlns="http://www.collada.org/2005/11/COLLADASchema" version="1.4.1"> ``` ... <library_geometries> <geometry id="Plane-tex-mesh-0" name="Plane-tex"> <mesh> ... <polylist count="12" material="lambert0-material"> <input offset="0" semantic="VERTEX" source="..." /> <input offset="1" semantic="NORMAL" source="..." /> <input offset="2" semantic="TEXCOORD" set="0" source="..." /> ... </polylist> </mesh> </geometry> </library_geometries> ... ``` </COLLADA> ``` This imports correctly into [[http:*www.open3mod.com/ | Open3Mod]] and validates against the [[https:*www.khronos.org/files/collada_schema_1_4_1.xsd | COLLADA xml schema]]. However, (WARNING) Blender ignores the vertex normals when importing. Excluding the normals altogether from the COLLADA file results in the same normals being generated. This leads me to believe that they are simply ignored. I tried looking at the blender code [[https://developer.blender.org/diffusion/B/browse/master/source/blender/collada | here]], but couldn't really find where the relevant part of the xml is processed. Any insight would be appreciated!
Author

Changed status to: 'Open'

Changed status to: 'Open'
Author

Added subscriber: @vinc

Added subscriber: @vinc

Added subscribers: @GaiaClary, @mont29

Added subscribers: @GaiaClary, @mont29
Gaia Clary was assigned by Bastien Montagne 2016-10-22 09:04:08 +02:00

@GaiaClary sounds more like a TODO than a bug to me, since support for custom vertex normals in Blender is fairly recent?

@GaiaClary sounds more like a TODO than a bug to me, since support for custom vertex normals in Blender is fairly recent?

Added subscriber: @RecepAslantas

Added subscriber: @RecepAslantas
Member

Vertex Normal import is not yet added. I will look into this shortly.

Vertex Normal import is not yet added. I will look into this shortly.
Author

In #49814#415353, @GaiaClary wrote:
Vertex Normal import is not yet added. I will look into this shortly.

Thank you. Still very much looking forward to this!

> In #49814#415353, @GaiaClary wrote: > Vertex Normal import is not yet added. I will look into this shortly. Thank you. Still very much looking forward to this!

Added subscriber: @MelonSpeedruns

Added subscriber: @MelonSpeedruns

Was this ever looked at? It seems like a pretty big issue to me.

Was this ever looked at? It seems like a pretty big issue to me.
Member

arghh, yes, i have this still on my list. I had to pause my work on the Blender Collada module for a while, but i am eager to get back on this as soon as possible, to make sure the Collada module will be ready for Blender 2.8

I also believe the support for importing custom normals is not a big thing to do. But - if you like to do so - a patch (based on the collada branch) is always welcome and might speed up the implementation a lot :)

arghh, yes, i have this still on my list. I had to pause my work on the Blender Collada module for a while, but i am eager to get back on this as soon as possible, to make sure the Collada module will be ready for Blender 2.8 I also believe the support for importing custom normals is not a big thing to do. But - if you like to do so - a patch (based on the collada branch) is always welcome and might speed up the implementation a lot :)
Gaia Clary was unassigned by Dalai Felinto 2019-12-23 16:36:55 +01:00

Added subscriber: @EatThePath

Added subscriber: @EatThePath

Speaking up as a user, the lack of working normal import is a pretty serious stumbling block for some things I would very much like to do. The only working toolchains for editing models for the Freespace Open engine rest on exporting from a special engine format(pof) to collada, editing in blender, exporting from blender to collada, and then reconverting back to .pof. The exporters from pof output normal data, not split edges or verts. Without normal import anyone making geometry changes has to just hope there's an autosmooth value that more or less reproduces the model's original state, which is rarely practical.

Speaking up as a user, the lack of working normal import is a pretty serious stumbling block for some things I would very much like to do. The only working toolchains for editing models for the Freespace Open engine rest on exporting from a special engine format(pof) to collada, editing in blender, exporting from blender to collada, and then reconverting back to .pof. The exporters from pof output normal data, not split edges or verts. Without normal import anyone making geometry changes has to just hope there's an autosmooth value that more or less reproduces the model's original state, which is rarely practical.

Added subscriber: @KevinCurry_Unity

Added subscriber: @KevinCurry_Unity

Added subscriber: @myroncarey

Added subscriber: @myroncarey

This issue was referenced by 22bf5ba4d1

This issue was referenced by 22bf5ba4d1526c9e942a2dbd6f25e3932e9d71f2
Member

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Gaia Clary self-assigned this 2022-09-14 15:26:47 +02:00
Member

@myroncarey Thanks again for your work on this patch! It has finally found its way into the master branch.

@myroncarey Thanks again for your work on this patch! It has finally found its way into the master branch.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
9 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#49814
No description provided.