11-17-2025, 11:14 PM
Hi Steve
thanks for replying!
Yeah I must say that the rounding argue is very logical.
So now it stands the issue about 32bit screen made by _NEWIMAGE.
Please give a second look at the second screenshot posted at #1.
you can notice that only the last 3 rows of the 10 rows PRINTed are visible...--> print viewport has a part out of the window
going deeper
you can see that the box drawn around the window is whole visible in SCREEN legacy mode, but not in SCREEN _NEWIMAGE (W,H,32) -->graphic viewport has a part out the window
following this path
you can see also that the two diagonals are not whole visible --> graphic viewport has a part out of the window
and you can see too that the center of the viewport is not at centre of the window --> graphic viewport has a part out of the window.
if you take a look at this screenshot got compiling the code of Petr Detect a point in a triangle you can notice that in Lubuntu you cannot see any output as text of the 1st row cause it is not visible.
![[Image: image-2025-11-17-232114908.png]](https://i.ibb.co/9dXwQnt/image-2025-11-17-232114908.png)
but if you modify the code from LOCATE 1 to LOCATE 5 , now you'll watch the text output in the upper left corner.
This issue affects also OpenGL graphics.
Please run the demo in Lubuntu, or test your Linux OS to see if it is so also there.
My question is : is the issue of viewport only in Lubuntu?
Thanks for your attention.
thanks for replying!
Yeah I must say that the rounding argue is very logical.
So now it stands the issue about 32bit screen made by _NEWIMAGE.
Please give a second look at the second screenshot posted at #1.
you can notice that only the last 3 rows of the 10 rows PRINTed are visible...--> print viewport has a part out of the window
going deeper
you can see that the box drawn around the window is whole visible in SCREEN legacy mode, but not in SCREEN _NEWIMAGE (W,H,32) -->graphic viewport has a part out the window
following this path
you can see also that the two diagonals are not whole visible --> graphic viewport has a part out of the window
and you can see too that the center of the viewport is not at centre of the window --> graphic viewport has a part out of the window.
if you take a look at this screenshot got compiling the code of Petr Detect a point in a triangle you can notice that in Lubuntu you cannot see any output as text of the 1st row cause it is not visible.
![[Image: image-2025-11-17-232114908.png]](https://i.ibb.co/9dXwQnt/image-2025-11-17-232114908.png)
but if you modify the code from LOCATE 1 to LOCATE 5 , now you'll watch the text output in the upper left corner.
This issue affects also OpenGL graphics.
Please run the demo in Lubuntu, or test your Linux OS to see if it is so also there.
Code: (Select All)
Dim Shared GlInit As Integer
GlInit = 0
Screen 0
Print "please press in order these keys to go on with the demo..."
Print " q w e. This demo starts after 3 seconds!"
Sleep 3
Screen _NewImage(1000, 800, 32)
Locate 1
Print "SCREEN mode 32 bit: first row" ' you cannot read this
Locate 5
Print "Press q to continue" ' you can read this
Do
Loop Until InKey$ = "q"
GlInit = 1
Do
' you see a triangle truncated at the top
Loop Until InKey$ = "w"
Screen 12
Locate 1
Print "SCREEN mode legacy 12: first row"
Do
' you see a regular triangle
Loop Until InKey$ = "e"
End
Sub _GL
If GlInit = 0 Then Exit Sub
_glViewport 0, 0, _Width(0), _Height(0)
_glClearColor 0, 0, .1, .5
_glClear _GL_COLOR_BUFFER_BIT Or _GL_DEPTH_BUFFER_BIT
_glBegin (_GL_TRIANGLES)
_glColor3f 1, .5, .5
_glVertex2f -1, -1 ' left down vertex
_glColor3f .5, 1, .5
_glVertex2f 1, -1 ' right down vertex
_glColor3f .5, .5, 1
_glVertex2f 0, 1 'middle up vertex
_glEnd
_glFlush
End Sub
My question is : is the issue of viewport only in Lubuntu?
Thanks for your attention.

