Page 1 of 2

Important and urgent feature request

Posted: Sun May 07, 2017 8:17 am
by rohandalvi
Hello,

Firstly the feature request,

I wanted to know if Octane can read more than 3 UV channels.

Now let me explain why I need that.

I am a Houdini trainer and I use Octane to render most of houdini scenes. At least I have for the past year. I'm putting a link to my website below so you can take a look at my work.
http://www.rohandalvi.net/home

When it comes to Houdini, Octane has one major restriction. It can't read Attributes. I have been able to create a workaround for this by transferring attributes to UVs. I even made a free tutorial for it.
https://vimeo.com/172594655

But this method only works for Float values and not for actual point colors. A few days back I figured out a way to make it work. The idea was to transfer each color channel to an individual UV channel.
transfer.jpg
Then in the shader I use individual UV channels to drive a simple white to black gradient which in turn controls a ramp. Each ramp represents a color channel. So one ramp goes from red to black, the second goes from green to black and the third from blue to black.Then I add them together.

Channel ramp
channel ramps.jpg
and it works perfectly.
end result.jpg
The problem is that because Octane can only read 3 UV channels, after doing this I have no UV channels left for standard texturing.

Which brings me back to my request. If Octane can read say 10 UV channels, then I can devote 3 channels for point colors and a couple for attributes and still have a few more left for standard texturing.

Until a more permanent solution to attributes can be worked out, this is a really simple and usable workaround. I don't know how long a feature like this would take, but if it can implemented quickly I'll be really happy and so will be a lot of Houdini Octane users.

regards
Rohan Dalvi

Re: Important and urgent feature request

Posted: Sun May 07, 2017 10:15 am
by calus
I think you're doint it wrong,
each UVset contain 2 channels, U and V so you can use only 2 UVsets to get vertex colors in Octane :

That's how I do this in maya
Given 3 UVsets : UVset1 (U1,V1) , UVset2 (U2,V2), UVset3 (U3,V3)
- I keep UVset1 for real UV
- I copy (clamped ) values: Red to U2 , Green to V2, Blue to U3, Alpha to V3
- To get back the values as textures in Octane I use gradients and "Add texture" nodes :
1 Black to Red U-ramp using UVset2 + 1 Black to Green V-ramp using UVset2 + 1 Black to Blue U-ramp using UVset3 = 1 RGB texture
1 Black to White V-ramp using UVset3 = 1 greyscall mask texture

Re: Important and urgent feature request

Posted: Sun May 07, 2017 10:24 am
by rohandalvi
Hi,

Could you post a screenshot of you node tree. It will be easier to understand. Also how do you split up U and V to drive separate textures. The meshUV node only gives a single output?

regards
Rohan

Re: Important and urgent feature request

Posted: Sun May 07, 2017 11:40 am
by calus
rohandalvi wrote: Could you post a screenshot of you node tree.
:) As I said that's how I do this in MAYA and I use python to transfert values from vertexColor to UV coordinates (but I could use Soup nodes).

Anyway it's way easier out-the-box in Houdini as in your example,
But it seems you're only using the V coordinate, maybe your VEXexpression should be more like this to use both U and V coordinates: ( Alpha component might be specific to Maya Vertex Color )
rohandalvi wrote: Also how do you split up U and V to drive separate textures. The meshUV node only gives a single output?
No split is needed you can composite back the colors in one texture exactly the same way you do it in your example,
except that for U gradient (for Red and Blue channel ) you have to add a tranform node with 2d rotation of 90 degres (or use a different gradient Image already U oriented).

Re: Important and urgent feature request

Posted: Sun May 07, 2017 12:42 pm
by rohandalvi
Hi,

Thanks a lot for your help. It worked. :D

Now I have one UV channel free.

When I make a video of this, I'll definitely give you a credit. :)

But I would still like more than 3 UV channels for store additional attributes.

regards
Rohan

Re: Important and urgent feature request

Posted: Sun May 07, 2017 1:12 pm
by calus
rohandalvi wrote: But I would still like more than 3 UV channels for store additional attributes.
While it would be nice to have unlimited UVset, don't forget in our case they are just used as a workaround to another missing feature.
I think the true needed feature is not more UVset but to make Octane capable to read arbitrary vertex attributes,(AKA vertex color sets)
I think it's already the case as Octane is able to read vertex velocity data for Motion blur of face varying mesh.
Maybe the only thing left to implement in Octane is a convention for this arbitray attributes and a way to read them directly as texture.
Anyway it would be way more efficient than the current UVset workaround.

Re: Important and urgent feature request

Posted: Sun May 07, 2017 1:18 pm
by rohandalvi
I agree 100% but until that day comes when Octane can read any arbitrary attributes at least having unlimited UV sets lets us do what we want to do.

Which is why I asked for more UV sets rather than the usual complaint that Octane should be able to read attributes and the answer to which always is , Wait for Octane 3.1.

I'm guessing that this is easier to implement so this might actually happen sooner. :)

Re: Important and urgent feature request

Posted: Sun May 07, 2017 7:44 pm
by Goldorak
rohandalvi wrote:Hello,

Firstly the feature request,

I wanted to know if Octane can read more than 3 UV channels.

Now let me explain why I need that.

I am a Houdini trainer and I use Octane to render most of houdini scenes. At least I have for the past year. I'm putting a link to my website below so you can take a look at my work.
http://www.rohandalvi.net/home

When it comes to Houdini, Octane has one major restriction. It can't read Attributes. I have been able to create a workaround for this by transferring attributes to UVs. I even made a free tutorial for it.
https://vimeo.com/172594655

But this method only works for Float values and not for actual point colors. A few days back I figured out a way to make it work. The idea was to transfer each color channel to an individual UV channel.
transfer.jpg
Then in the shader I use individual UV channels to drive a simple white to black gradient which in turn controls a ramp. Each ramp represents a color channel. So one ramp goes from red to black, the second goes from green to black and the third from blue to black.Then I add them together.

Channel ramp
channel ramps.jpg
and it works perfectly.
end result.jpg
The problem is that because Octane can only read 3 UV channels, after doing this I have no UV channels left for standard texturing.

Which brings me back to my request. If Octane can read say 10 UV channels, then I can devote 3 channels for point colors and a couple for attributes and still have a few more left for standard texturing.

Until a more permanent solution to attributes can be worked out, this is a really simple and usable workaround. I don't know how long a feature like this would take, but if it can implemented quickly I'll be really happy and so will be a lot of Houdini Octane users.

regards
Rohan Dalvi
I understand the issue , and yes, UV3 is viable for vertex color or other channels. We will have to see how far we can take this in pure OSL (e.g. maybe OSL can look up extra UVs without using a vertex channel) coming up in 3.1, but eventuallly I would like to see this addressed directly if the prior approaches have any user facing limits.

Re: Important and urgent feature request

Posted: Mon May 08, 2017 3:13 am
by rohandalvi
Hi,

Eventually, as Pascal Andre said , the proper solution is to have a node that can directly read any custom attribute such as vertex colors or velocity or any other arbitrary attribute that a user would create. That's how mantra , Arnold or any other render engine in Houdini do it. They just have a node called Custom Data , which can be used to read custom attributes and then drive any value at shader level . This is not just applicable to Houdini but any other software including Octane Standalone because Alembic can store custom attributes as well.

But till something like that can be implemented, the UV method is a fairly crude but usable workaround which is why I asked for more uv channel. However if a method to directly read attributes can be implemented then additional uv channel won't be required.

Regards
Rohan

Re: Important and urgent feature request

Posted: Mon May 15, 2017 2:48 pm
by tigher
A custom attribute feature is one that I too would like to see implemented in Octane for Houdini, custom attributes have to be the most desirable feature for Octane in Houdini. The workaround works but it's limited, I'll often use several custom attributes per shader and would very much like to see support for more. Hope this feature becomes some what a priority, it would really bring a lot of people on board for octane instead of going for redshift.