question

Tyler Furreboe avatar image
Tyler Furreboe asked ·

Attempting to compile driver_display_callback

I have this set up in Visual Studio: Display Driver, though when compiling I receive an error that I did not define a `main()` method, from which file in the Arnold SDK do I need to import in order to have this entry point defined?

render
screenshot-152.png (15.4 KiB)
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Max Tarpini avatar image
Max Tarpini answered ·

Ok so a dll is good :) btw don't forget to compile it in Release mode at some point with ProjectProperty -> C/C++ -> Optimization set to at least O2. Then before you can use it .. you need to let Arnold source your library with ie from kick cli .. -l "pathtomylib"

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

@Max Tarpini Alright I think I finally got it, I just dragged the .dll file into the

`Arnold-5.1.1.0-windows\plugins` folder, and finally it appears that it can find this display driver, now I have to try and call it's method, it appears this method does not exist, any idea how to get access to the node's method?

`cb = arnold.DriverDisplayCallbackMtd(_callback)`
`arnold.AiNodeSetPtr(driver, "callback", cb)`

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

I do see this though:

loading plugins from C:\Users\tyler\source\repos\driver_display_callback\x64\Release\ driver_display_callback  driver

Still not sure how I can use it with `arnold.AiNode("driver_display_callback")` though.. hmm..

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

I'm still getting this issue:

arnold.AiNode("driver_display_callback") fails with: ERROR | node "driver_display_callback" is not installed

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

@Max Tarpini I got this:

C:\Users\tyler\source\repos\driver_display_callback\x64\Release>kickArnold 5.1.1.0 [e338d869] windows icc-17.0.2 oiio-1.7.17 osl-1.9.0 vdb-4.0.0 clm-1.0.3.513 rlm-12.2.2 2018/05/23 00:19:24kick: No arguments. Try kick --help for a command summary
Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

Here's the log after compiling `driver_display_callback.cpp`:


screenshot-157.png (18.7 KiB)
Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Tyler Furreboe avatar image
Tyler Furreboe answered ·

@Max Tarpini

I've tried compiling both a dynamic and standard library - I have no errors now, but it doesn't appear that the display_driver_callback node is being added to Arnold:

`arnold.AiNode("driver_display_callback")` fails with: ERROR | node "driver_display_callback" is not installed

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Max Tarpini avatar image
Max Tarpini answered ·

Shouldn't you compile a library instead of an exe ?

Share
10 |600 characters needed characters left characters exceeded

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 5 attachments (including images) can be used with a maximum of 2.0 MiB each and 9.8 MiB total.

Welcome to the Arnold Answers community.

This is the place for Arnold renderer users everywhere to ask and answer rendering questions, and share knowledge about using Arnold, Arnold plugins, workflows and developing tools with Arnold.

If you are a new user to Arnold Answers, please first check out our FAQ and User Guide for more information.

When posting questions, please be sure to select the appropriate Space for your Arnold plugin and include the plugin version you are using.

Please include images, scene and log files whenever possible as this helps the community answer your questions.

Instructions for generating full verbosity log files are available for MtoA, MaxtoA, C4DtoA, HtoA, KtoA, and Kick.

If you are looking for Arnold Documentation and Support please visit the Arnold Support site.

To try Arnold please visit the Arnold Trial page.

Bottom No panel present for this section.