Elvas Tower: HDR shader and Open Rails - Elvas Tower

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

HDR shader and Open Rails Rate Topic: -----

#1 Inactive_Gregory_777_*

  • Group: Status: Passengers (Obsolete)

Posted 28 November 2013 - 08:58 PM

Hello, all!

I'm Gregory and i'm from Moscow, Russia.

I try to change some OR sources for me: correct cabfonts, diesel smoke appearance, and some little changes to my OR (you can see my attmpts at trainsim.ru forum here, and here).

Now i try to add a XNA Bloom Postprocess to Open Rails "RunActivity" subproject, but receive a crush with an error message following: "the active render target and depth stencil surface must have the same pixel size and multisampling type" when i'm going fullscreen. I can not find a working solution to the problem. Any ideas?

Best regards,
Gregory.

This post has been edited by Gregory_777: 28 November 2013 - 09:45 PM


#2 User is online   James Ross 

  • Open Rails Developer
  • Group: Status: Elite Member
  • Posts: 5,491
  • Joined: 30-June 10
  • Gender:Not Telling
  • Simulator:Open Rails
  • Country:

Posted 29 November 2013 - 01:11 AM

View PostGregory_777, on 28 November 2013 - 08:58 PM, said:

I try to change some OR sources for me: correct cabfonts, diesel smoke appearance, and some little changes to my OR (you can see my attmpts at trainsim.ru forum here, and here).


There are no known issues with cab fonts, so you'll have to explain that more clearly.

View PostGregory_777, on 28 November 2013 - 08:58 PM, said:

Now i try to add a XNA Bloom Postprocess to Open Rails "RunActivity" subproject, but receive a crush with an error message following: "the active render target and depth stencil surface must have the same pixel size and multisampling type" when i'm going fullscreen. I can not find a working solution to the problem. Any ideas?


It is impossible to know exactly what is wrong with your code changes without actually seeing them, but I think the error message is itself is clear - the render target and depth stencil must have the same size/multisampling.

#3 User is offline   disc 

  • Foreman Of Engines
  • Group: Private - Open Rails Developer
  • Posts: 818
  • Joined: 07-October 12
  • Gender:Male
  • Simulator:OpenRails
  • Country:

Posted 29 November 2013 - 04:49 AM

"the active render target and depth stencil surface must have the same pixel size and multisampling type"

I get the same error message when i start fraps when OR is running already :pleasantry:

#4 Inactive_Gregory_777_*

  • Group: Status: Passengers (Obsolete)

Posted 29 November 2013 - 04:09 PM

This is my cumulative patch for diesel smoke, russian DC-catenary, cabfont and some other staff. It works for me.
And so, this is my HRD attempt...

This post has been edited by Gregory_777: 29 November 2013 - 04:12 PM


#5 User is online   James Ross 

  • Open Rails Developer
  • Group: Status: Elite Member
  • Posts: 5,491
  • Joined: 30-June 10
  • Gender:Not Telling
  • Simulator:Open Rails
  • Country:

Posted 29 November 2013 - 04:38 PM

It's very hard for me to tell what's been modified in the cumulative patch, so I can't comment on that right now.

The problem with the bloom effect code is that you've used XNA's Component rendering and this is not the same way the rest of OR works. I don't know if XNA's Component provides notifications on fullscreen, but OR's rendering does - and this is critical when you've got a ResolveTexture2D that must match the back buffer. The back buffer changes when going fullscreen (or resizing the window, but that's disabled). Have a look at the "window glass" effect code in WindowManager.cs and related code. That also applies a fullscreen quad effect.

Hope that helps.

#6 Inactive_Gregory_777_*

  • Group: Status: Passengers (Obsolete)

Posted 29 November 2013 - 06:40 PM

Thank You, James. Now i understand my mistake. I'm not a beginner in a c#, but a novice in XNA.

#7 User is offline   gpz 

  • Superintendant
  • Group: Status: Elite Member
  • Posts: 1,772
  • Joined: 27-October 12
  • Gender:Male
  • Location:Budapest
  • Simulator:OpenRails
  • Country:

Posted 30 November 2013 - 04:41 AM

I attach Gregory's patch as it should look like.

Attached File(s)



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users