GL Render Problem Max5 and Max6

Dec 22, 2011 at 2:08pm

GL Render Problem Max5 and Max6

Hi i have a sample patch from max5 which is working fine. I render an 3d scene to texture, to use them in another 3d scene as texture. But with max6 it doesnt work. I tried it with jit.gl.node but didnt find an solution. here is my old working patch.

– Pasted Max Patch, click to expand. –
#60810
Dec 22, 2011 at 4:14pm

Seems to work on my Max6
I upgraded last night to v. 6.0.2
I have Mac Osx 10.6.7

#218869
Dec 22, 2011 at 5:12pm

works here. mac osx as well.
as far as i understand 6.02 adresses some of these rendering issues with open gl.

#218870
Dec 22, 2011 at 6:14pm

I updated max to 6.0.2 but i got the same error message. Perhaps it is a problem withne the new MBP and Lion? I ve atached the max window failure, which i get.

[attachment=180002,3113]

Attachments:
  1. Bildschirmfoto20111222um19.09.38.png
#218871
Dec 23, 2011 at 7:47am

I can confirm, runs fine with no errors in Max 5, but Max 6 shows no texture & same error message – running Lion on Macbook Pro.

pH

#218872
Dec 27, 2011 at 5:38pm

Here’s a working version of this patch in Max6. A couple of notes about your patch. @fsaa is a 0/1 flag, so @fsaa 5 has no meaning. It’s exactly the same as @fsaa 1. You were banging the message “usetexture Scene, to_texture, erase” twice, which may work fine but is unnecessary. You should only need to do this once per frame. Also, [qmetro 2] doesn’t make a lot of sense for video rendering since the fastest your screen will update is likely 60fps. [qmetro 2] is theoretically 500fps but really just ends up clogging the scheduler.

FWIW, the method called on invalid object warning is harmless and now fixed.

Ok, so now for the Max6 stuff. Max 6.0.2 has a new feature in jit.window for sharing textures across contexts in a much more easily understood manner. There’s a jit.window @shared (0/1) attribute. If enabled, the context will be able to share textures with any other context that is also shared. I would recommend using this over jit.gl.render @shared_context . @shared_context makes use of the jit.window @shared 1 behind the scenes. The way it works is there’s a root context that is shared between all of the shared contexts so you can have a number of contexts sharing textures instead of just 2.

– Pasted Max Patch, click to expand. –
#218873
Dec 29, 2011 at 6:17pm

tanx!

one note: it worked fine after reversing the metro’s bang order, first jit.qt.movie then t.

#218874
Jan 3, 2012 at 8:29am

thanks for your reply, i was on holidays the last days. yeah that with the fsaa is right. and alos i changed the bang order with movie and render. and it works fine, but it is really unstable. the patch is crashing max after a few minutes or changes between fullscreen.

but thnkx for your reply

#218875
Jan 3, 2012 at 3:12pm

Same here. Max crashes on going fullscreen and even a couple of times when moving the mouse inside one of the render windows…

I adapted my performance system to work like Wes’ patch but it also crashes after a couple of minutes.

Seems like something about context sharing is not quite right.

Max 6.0.2 on OSX 10.7.2.

#218876
Jan 4, 2012 at 8:32pm

Interesting… My MacBookPro doesn’t have these problems.
It’s a C2D cpu + ATI Radeon X1600 gpu running Max 6.0.2 on OSX 10.6.8 (Snow Leopard).

The machine giving me trouble is a hackintosh with i7-2600k cpu + ATI HD6870 2GB gpu. It’s running Max 6.0.2 on OSX 10.7.2 (Lion).

On the MacBookPro I also didn’t need to switch the bang order like I had to on the troublesome machine. Without reversing I was getting low fps and errors in the Max window. (I’m away from the computer so can’t check the exact error messages right now)

Could it be an issue with Lion and/or the ATI HD6870 gpu? The gpu has 2GB RAM which isn’t very common on HD6870′s.

#218877
Jan 4, 2012 at 8:34pm

@audiovisualist: what’s your system like?

#218878
Jan 4, 2012 at 9:24pm

For those getting crashes with the patch. Would you mind posting steps to reproduce as well as the information in the OpenGL Status window?

thanks!
wes

#218879
Jan 5, 2012 at 10:16am

My system is a MBP 2.4ghz i7 with 8GB Ram, OS 10.7.2 Lion ad Max 6.02. I made 2 captures from the OpenGl, with and without fullscreen. See attached Files.

Thanks.

Attachments:
  1. NotFullscreen.rtf
#218880
Jan 5, 2012 at 10:41am

case 1: wes’ patch unmodified

– Pasted Max Patch, click to expand. –

runs but with errors in the max window. this one only once when firing up the metro:

jit.gl.texture: unsupported texture format!

and random combinations of these thrown every frame:

trying to use glproctable while either context or proctable is invalid. using global proctable
ob3d_draw_end: no context

gl status attached below.

#218881
Jan 5, 2012 at 10:43am

status

Attachments:
  1. glstatus1.rtf
#218882
Jan 5, 2012 at 10:49am

case 2: wes’ patch with bang order reversed

– Pasted Max Patch, click to expand. –

runs but freezes max on fullscreen, using exposé and by itself after a little while.

throws these 4 errors once when starting metro:

trying to use glproctable while either context or proctable is invalid. using global proctable
trying to use glproctable while either context or proctable is invalid. using global proctable
trying to use glproctable while either context or proctable is invalid. using global proctable
trying to use glproctable while either context or proctable is invalid. using global proctable

gl status attached

Attachments:
  1. glstatus2.rtf
#218883
Jan 5, 2012 at 10:54am

interestingly both patches above seem to run fine when using qmetro instead of metro, but the GeoA window doesn’t show anything, only Video does

#218884
Jan 5, 2012 at 1:51pm

Yeap, that is right and i can confirm this. But i have also no idea where the problem can be found.

#218885
Feb 17, 2012 at 4:32pm

This issue seems to be fixed in the 6.0.4 update.

#218886

You must be logged in to reply to this topic.