Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Bindings - other languages
»
DotNet
»
[2.0 RC] View bug
Print
Pages: [
1
]
Author
Topic: [2.0 RC] View bug (Read 2852 times)
0 Members and 2 Guests are viewing this topic.
SymegPL
Newbie
Posts: 13
[2.0 RC] View bug
«
on:
January 27, 2013, 06:10:17 pm »
Hello! Sorry for my bad english.
I have problem with View class. When i apply new position, rotation etc. to view it works, but nothing changes on screen. It was only change when i use SetView method.
Exapmle:
window
.
GetView
(
)
.
Move
(
new
Vector2f
(
5
,
5
)
)
;
//nothing changes on the screen
window
.
SetView
(
window
.
GetView
(
)
.
Move
(
new
Vector2f
(
5
,
5
)
)
)
;
//only now view was applied to the screen
It is bug or not?
Thanks for replies.
Utermiko
«
Last Edit: January 27, 2013, 06:27:47 pm by Utermiko
»
Logged
Laurent
Administrator
Hero Member
Posts: 32498
Re: [2.0 RC] View bug
«
Reply #1 on:
January 27, 2013, 06:54:56 pm »
Yes, you need to call SetView to change the view. The fact that you can modify GetView() directly is just a limitation of the C# language (there's no
const
type).
Logged
Laurent Gomila - SFML developer
SymegPL
Newbie
Posts: 13
Re: [2.0 RC] View bug
«
Reply #2 on:
January 27, 2013, 07:08:38 pm »
But classes are passed by reference, not value.
@EDIT I saw on the source. GetView always create new "View" object.
Thank you.
«
Last Edit: January 27, 2013, 07:11:52 pm by Utermiko
»
Logged
Print
Pages: [
1
]
SFML community forums
»
Bindings - other languages
»
DotNet
»
[2.0 RC] View bug
anything