PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

All bugs related to the 3D engine
User avatar
pf shadoko
Enthusiast
Enthusiast
Posts: 396
Joined: Thu Jul 09, 2015 9:07 am

PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by pf shadoko »

DrawingBuffer() in a texture causes a crash on x86
Works on x64
Fred
Administrator
Administrator
Posts: 18301
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by Fred »

Could you post a snippet to show the issue ?
User avatar
pf shadoko
Enthusiast
Enthusiast
Posts: 396
Joined: Thu Jul 09, 2015 9:07 am

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by pf shadoko »

in fact, it concerning all 2ddrawing fcts

Code: Select all

InitEngine3D()
InitSprite():InitKeyboard():InitMouse()

ExamineDesktops()
OpenWindow(0, 0,0, DesktopWidth(0)*0.8,DesktopHeight(0)*0.8, "test - [Esc] quit",#PB_Window_ScreenCentered)
OpenWindowedScreen(WindowID(0), 0, 0, WindowWidth(0), WindowHeight(0), 0, 0, 0)

CreateTexture(0,256,256)
StartDrawing(TextureOutput(0))
Debug DrawingBuffer()
Box(0,0,200,200,$ff00ff)
StopDrawing()
Fred
Administrator
Administrator
Posts: 18301
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by Fred »

Seems to work here on both x86 and x64:

Code: Select all

; ------------------------------------------------------------
;
;   PureBasic - Text3D
;
;    (c) Fantaisie Software
;
; ------------------------------------------------------------
;

InitEngine3D()
InitSprite()
InitKeyboard()
InitMouse()

ExamineDesktops():dx=DesktopWidth(0)*0.8:dy=DesktopHeight(0)*0.8
OpenWindow(0, 0,0, DesktopUnscaledX(dx),DesktopUnscaledY(dy), " Text3D - [Esc] quit",#PB_Window_ScreenCentered)
OpenWindowedScreen(WindowID(0), 0, 0, dx, dy, 0, 0, 0)

Add3DArchive(#PB_Compiler_Home + "examples/3d/Data/Textures", #PB_3DArchive_FileSystem)
Add3DArchive(#PB_Compiler_Home + "examples/3d/Data/fonts", #PB_3DArchive_FileSystem)
Parse3DScripts()

CreateCube(0, 2)

CreateMaterial(0, LoadTexture(0, "Caisse.png"))

StartDrawing(TextureOutput(0))
Debug DrawingBuffer()
Box(0,0,200,200,$ff00ff)
StopDrawing()

CreateEntity(0, MeshID(0), MaterialID(0))

CreateText3D(0, "Hello world")
Text3DColor(0, RGBA(255, 0, 0, 255))
Text3DAlignment(0, #PB_Text3D_HorizontallyCentered)
AttachEntityObject(0, "", Text3DID(0))
MoveText3D(0, 0, 2, 2)

RotateEntity(0, 0, -70, 0)

CreateCamera(0, 0, 0, 100, 100)
MoveCamera(0, 0, 0, 10, #PB_Absolute)

Repeat
  While WindowEvent():Wend
  
  ExamineKeyboard()
  
  RotateEntity(0, 1, 1, 1, #PB_Relative)
  
  RenderWorld()
  FlipBuffers()
Until KeyboardPushed(#PB_Key_Escape) Or Quit = 1
Can anybody else confirm ?
PeDe
Enthusiast
Enthusiast
Posts: 298
Joined: Sun Nov 26, 2017 3:13 pm

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by PeDe »

Works here: PB v6.30b2 x86, Linux LMDE 6 (32 bit)

Peter
User avatar
pf shadoko
Enthusiast
Enthusiast
Posts: 396
Joined: Thu Jul 09, 2015 9:07 am

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by pf shadoko »

This problem must have been corrected in b2.

So it's [DONE]
User avatar
mk-soft
Always Here
Always Here
Posts: 6270
Joined: Fri May 12, 2006 6:51 pm
Location: Germany

Re: PB 6.30 b1 x86 : DrawingBuffer() with TextureOutput

Post by mk-soft »

Not work on macOS (Intel)
Invalid Memory Access ...

If StartDrawing(TextureOutput(0)) ... failed
My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
Post Reply