What does Natron use for the Text node?

Hello again,

This is a follow up to my previous thread (Compiling openfx-io throws errors?), but since that was resolved, now I need to make sure I’m on the right track.

When I right click inside Natron to add this node Natron->Draw->Text, is this the same OFX code found inside openfx-io->OIIO?

Inside OIIO, there is OIIOText, and when I compiled it alone, and tried to use it inside Black Magic Davinci Resolve from its Fusion Tab (Node Compositor), I couldn’t get any output from it.

It doesn’t render anything, it even turns the previewer to a Blank windows as you can see on the left side of it:

What I have also noticed was the inability of the Font drop-down menu to detect any fonts, so I had to type it manually, and I’m wondering whether that has to do with it?

The reason I’m doing this returns to Fusion inability to support Arabic fonts, and their support says they’re aware of it, but nothing is waving in the horizon to solve it, while Natron does it perfectly :slight_smile: So, I want to use Natron’s Text node inside of Fusion.

Natron’s text node is located in https://github.com/NatronGitHub/openfx-arena/tree/master/Text , but I don’t think it’s compatible with Fusion. I have access to Fusion 9/16 and can probably fix the issues.

You rock man! Thanks a bunch indefinitely!

I will start meddling with the source code now.

As for Fusion, it doesn’t support Arabic, if you try to use any 3D transformation/title/whatever, it will turn into Squares.

If you just try to use the Text with no effects, it gets rendered separately, while Arabic letters are written in a recursive way, which will be more explained in my email to Black Magic Design support, here’s a screenshot:

Then this:

Unfortunately, here’s what I got as a response:

Arabic is super crucial to my work, and it has to work, and it defeats the whole purpose of using something like Fusion when I have to insert every word as a PNG!

I think TextOFX from Natron will trigger a crash in Fusion during init, I never cared to check into why since it’s made for Natron, but if there is a use case outside of Natron I’m willing to look into the issue (probably on Sunday).

If you want to test and build TextOFX make sure you have fontconfig and pango(cairo) installed. Just ask if you have build issues or something.

1 Like

Thanks man, the old OIIOText didn’t cause a crash, but several G’MICK ones did, so hopefully this would work.

If it will, then it will solve thousands of Arabic-users painful problem, it will just make the world a better place :slight_smile:

One more time, thanks a lot Rodlie.

So, it doesn’t crash Resolve/Fusion, which is a good thing, but it remains Blank.

This time, I have checked the log, and here’s the culprit I found:

[0x7fe8efdee000] | OpenFX               | WARN  | 2019-12-14 02:15:32,178 | propGetDimension: unknown object (NatronOfxPropNativeOverlays)
[0x7fe8efdee000] | OpenFX               | WARN  | 2019-12-14 02:15:32,179 | propGetDimension: unknown object (OfxParamPropChoiceEnum)

The apparent solution is to get this Natron-Independent, as it looks like it doesn’t find the “NatronOfxPropNativeOverlays”, which we can either recreate a stub for it to redirect/re-forward the call to whatever else can answer the propGetDimension method.

Now, we’re getting somewhere, and I will keep digging, and hopefully you guys can help, since you’re well versed with Natron code-base.

I will try to use OpenCL instead of CUDA too, because I believe you only have implemented OpenCL in Natron, if I’m not mistaken.

I forgot that I had Resolve on my laptop, yeah the plugin does not generate output. I will do some simple tests. The plugin is 100% CPU, no CUDA or OpenCL.

That’s even more fantastic; it should make it easier to be tracked.

P.S: I’m on Ubuntu Linux btw.

(post withdrawn by author, will be automatically deleted in 24 hours unless flagged)

So, now I know why I don’t use Resolve on my laptop, it trashes my disk for 15min after each quit, and stalls my machine the hole time … Anyway, I’m able to get output at least, but the plugin is not functional yet, the font list (_genFonts) needs to be adjusted, and I also disabled interactive stuff like move, scale, rotate etc for now.

The branch is https://github.com/NatronGitHub/openfx-arena/tree/fusion

I will look more into to this on Sunday as I then got access to a working installation of Fusion on a proper workstation. Feel free to play around with the code in the mean time :slight_smile:

1 Like

Wow. I just discovered a legend!

I tried on my end and it doesn’t show anything, while if I test the RichTextOFX it only shows the Alpha empty channel.

I will remove all the other plugins and re-check.

One thing that happened this time. My workstation froze for about 3-4 minutes right after I added the TextOFX, then it came back to normal, and we’re talking here about 32GB DDR4, and a Samsung NVe SSD with a 32 Thread / 16 cores threadripper workstation, and I can safely say it had never happened before.

I will check the log for it, but the mere view of you getting it to display on your end has given me real hope this should work.

It’s 4:25am here, and I guess it’s late there too, so get some rest and enjoy your weekend. You deserve a Merit Medal for what you’re doing :slight_smile:

I found the reason for the freeze, it was the font list generation, something weird is happening in Fusion. If you build from the fusion branch it will work, you just don’t have any fonts to select from.

Seems like we are on the same timezone, getting waaay to late :slight_smile:

1 Like

I can confirm now after closing Resolve Studio, my whole PC re-froze until now, and I don’t think it has something to do with the disk, since I’m using an SSD, and it might be a memory leak, or high CPU usage.

I will re-build the ofx in release mode without the richedit part and see.

lol, I can feel your coding adrenaline rush from here, so talk to you when you’re well rested, and I will keep digging on my side, and yes, this time, the fonts were correctly detected and shown in the drop-down menu.

If you can test later on, see if Arabic is rendered correctly on your end, as I couldn’t get it to render anything for some reason, while yours could.

It says I’ve reached my maximum post count for a new use and have to wait for 18 hours, so here’s the update:

I think my code isn’t up to date for some reason, may be the last push hasn’t been populated, as you will see on my screenshot, it still shows the features you have disabled on your end like the Rotate, Scale, Skew…etc

I will re-clone the git and see if I can pull the correct one.

The freezing I think comes from the generation of fonts, the plugin does something Fusion don’t like. I disabled the generation for now, seems to do the trick.

RichTextOFX is a custom plugin for Natron and should be ignored (it’s WIP and will never work in Fusion). I added a CMakeLists.txt in the Text folder so you can use that to build TextOFX, remember to use the fusion branch.

As long as the text widget in Fusion don’t strip any text or does some kind of filtering Arabic should work, my laptop is now off so can’t test until tomorrow.

Hi again,

After some more testing I have concluded that it’s easier for me to create a “Lite” edition of TextOFX for alternative OFX hosts like Fusion. I will not take too long as I have most functions in one lib.

I tested with Arabic text and they seem to work (I’m not a 100% sure how they are supposed to look).

1 Like

I was unable to add any more posts as a new user, and was asked to wait 18 hours, so my last update was added as an Edit to my previous one, and if you check the screenshot, you will see that the features you have disabled are still showing on the code I’m pullingز

After I traced the code, I can see the features being enabled at ofxsTransformInteract.cpp inside SupportExt and not inside the “Text” folder, so would you share you “SupportExt” folder plz?

New update:

I’ve stripped dozens of lines of code to remove all those features, but I don’t get any rendering, and just an assumption after checking the log file, I saw:

Read outside clip bounds - 2 [0, 0]

I have removed lots of positioning and centering methods, so could that be the problem? (hint: the same warning message was thrown even before removing any line of code too)

I have Tweeted you as well, since this forum restricted me from posting since yesterday.

@codernix I’ve bumped your user trust level from 0 to 1, I think that removes the post limitations.

1 Like

Thanks @paperdigits, I was super frustrated yesterday but I understand why that’s in place. Appreciate the act.

We can continue the discussion/development on https://github.com/fxarena/openfx-text as this is not related to Natron anymore.

1 Like

I totally Agree!