Cycles Standalone missing generated coordinates #49904

Closed
opened 2016-11-01 18:38:27 +01:00 by David · 16 comments

Something is broken with the nodes.

This is the example "scene_monkey.xml"
*The monkey should be Glass
*The ground should be checkerboard
http://imagizer.imageshack.com/img923/2464/reKxvE.png

*no changes from master on Win10 VS2013
*compiled and tested cycles standalone in both "rB Blender" and "rC Cycles"

I tested my compiled blender.exe, and the glass and checkerboard nodes work in blender, but something is not working in the standalone.

What it should look like:
http://www.blendernation.com/wp-content/uploads/2014/01/standalone.png

Something is broken with the nodes. This is the example "scene_monkey.xml" *The monkey should be Glass *The ground should be checkerboard http://imagizer.imageshack.com/img923/2464/reKxvE.png *no changes from master on Win10 VS2013 *compiled and tested cycles standalone in both "rB Blender" and "rC Cycles" I tested my compiled blender.exe, and the glass and checkerboard nodes work in blender, but something is not working in the standalone. What it should look like: http://www.blendernation.com/wp-content/uploads/2014/01/standalone.png
Author

Changed status to: 'Open'

Changed status to: 'Open'
Author

Added subscriber: @bocs

Added subscriber: @bocs
Member

Added subscriber: @MartijnBerger

Added subscriber: @MartijnBerger
Member

Seems cycles is not adding generated UV coordinates to the checker texture.

Seems cycles is not adding generated UV coordinates to the checker texture.
Author

This comment was removed by @bocs

*This comment was removed by @bocs*
Author
Found the commit where it broke standalone: https://developer.blender.org/rBc96ae81160ad1a943fafaca44a7d5e97c2d7a0d7 Before and After: http://imagizer.imageshack.com/img922/2615/3nec0A.png

Added subscribers: @MaiLavelle, @mont29

Added subscribers: @MaiLavelle, @mont29
Mai Lavelle was assigned by Bastien Montagne 2016-11-04 09:59:52 +01:00

@MaiLavelle, this seems to be for your desk? :)

@MaiLavelle, this seems to be for your desk? :)
Author

I hope this helps make a proper patch...
I noticed during debugging that it's missing the ATTR_STD_GENERATED attribute.

which led me to this...

This code was removed from intern/cycles/render/mesh.cpp

			/* todo: get rid of this exception, it's only here for giving some
			* working texture coordinate for subdivision as we can't preserve
			* any attributes yet */
			if (!triangle_mattr && req.std == ATTR_STD_GENERATED) {
				triangle_mattr = mesh->attributes.add(ATTR_STD_GENERATED);
				if (mesh->verts.size())
					memcpy(triangle_mattr->data_float3(), &mesh->verts[0], sizeof(float3)*mesh->verts.size());
			}

without code:
http://imagizer.imageshack.com/img924/6018/lz7Tjh.png

With code:
http://imagizer.imageshack.com/img924/4740/L1C8uH.png

Off Topic:
I'm trying to intergrate Cycles into Unity, this is from a few months ago
https://youtu.be/wNtFdrKwkfM?t=1m15s

I hope this helps make a proper patch... I noticed during debugging that it's missing the ATTR_STD_GENERATED attribute. which led me to this... This code was removed from intern/cycles/render/mesh.cpp ``` /* todo: get rid of this exception, it's only here for giving some * working texture coordinate for subdivision as we can't preserve * any attributes yet */ if (!triangle_mattr && req.std == ATTR_STD_GENERATED) { triangle_mattr = mesh->attributes.add(ATTR_STD_GENERATED); if (mesh->verts.size()) memcpy(triangle_mattr->data_float3(), &mesh->verts[0], sizeof(float3)*mesh->verts.size()); } ``` without code: http://imagizer.imageshack.com/img924/6018/lz7Tjh.png With code: http://imagizer.imageshack.com/img924/4740/L1C8uH.png Off Topic: I'm trying to intergrate Cycles into Unity, this is from a few months ago https://youtu.be/wNtFdrKwkfM?t=1m15s
Member

As far as I know Cycles standalone never provided generated coordinates, so its a bit odd to say that that commit caused this. Check that you're using updated repos/files.

Not sure what the correct solution is here, as generated coordinates come from Blender, I guess we can mimic the behavior?

As far as I know Cycles standalone never provided generated coordinates, so its a bit odd to say that that commit caused this. Check that you're using updated repos/files. Not sure what the correct solution is here, as generated coordinates come from Blender, I guess we can mimic the behavior?
Mai Lavelle changed title from Cycles Standalone Broken to Cycles Standalone missing generated coordinates 2016-11-11 14:28:31 +01:00
Member

well the xml does render correctly in older versions of cycles standalone. I.E. with generated coordinated. and there are no coordinates in that file.

well the xml does render correctly in older versions of cycles standalone. I.E. with generated coordinated. and there are no coordinates in that file.

Added subscriber: @brecht

Added subscriber: @brecht
Mai Lavelle was unassigned by Brecht Van Lommel 2016-11-12 17:01:13 +01:00
Brecht Van Lommel self-assigned this 2016-11-12 17:01:13 +01:00

We don't yet support arbitrary mesh attributes in the XML file reading, and ideally generated coordinates should be passed that way. But none are available we can still use the vertex coordinates as a fallback, I'll restore that code.

We don't yet support arbitrary mesh attributes in the XML file reading, and ideally generated coordinates should be passed that way. But none are available we can still use the vertex coordinates as a fallback, I'll restore that code.

This issue was referenced by blender/cycles@9da3452f3a

This issue was referenced by blender/cycles@9da3452f3a6126ddba2ed2655ea285df29db54a9

This issue was referenced by 111e2f5aba

This issue was referenced by 111e2f5abacc0d93b83de66d1cde8f37e60f1395

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
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
6 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#49904
No description provided.