Page 1 of 1

same code working in x64 but not in x86?

Posted: Sun Feb 01, 2015 11:08 pm
by T4r4ntul4
well maybe a vague title, but i have a strange thing going on:

i have this code:

Code: Select all

If InitEngine3D()
 
  InitSprite()
  InitKeyboard()
 
  ; get screen size
  ExamineDesktops()
  DesktopW = DesktopWidth(0)-10
  DesktopH = DesktopHeight(0)-60
 
  OpenWindow(0, 0, 0, DesktopW, DesktopH, "Rotating cube")
    OpenWindowedScreen(WindowID(0), 0, 0, DesktopW, DesktopH, 0, 0, 0)

    ; cube creation
    CreateCube(1,35)
    CreateEntity(1, MeshID(1), #PB_Material_None)
   
    ;-Camera
    CreateCamera(0, 0, 0, 100, 100)
    MoveCamera(0, 0, 0, 150, #PB_Absolute)
    CameraBackColor(0, RGB(0, 0, 40))
   
    ;-Light
    CreateLight(0, RGB(255,255,255), -10, 60, 10)
    AmbientColor(RGB(90, 90, 90))
   
    ; game loop
    Repeat
      Event = WindowEvent()
      ExamineKeyboard()
     
      ; rotate cube
      RotateEntity(1, 0.5, 0.5, 0.5, #PB_Relative)
     
      RenderWorld()
     
      FlipBuffers()
    Until KeyboardPushed(#PB_Key_Escape) Or Quit = 1
  EndIf
 
End
but for some reason its working on PB 5.31 (x64) but not on PB 5.31 (x86) the error says: POLINK: fatal error: toegang geweigerd. but compiling 3d things is just working.

what do i miss here?

Re: same code working in x64 but not in x86?

Posted: Sun Feb 01, 2015 11:34 pm
by Bisonte
That sounds like a virusscanner .... Try to deactive the scanner and compile it again...

Re: same code working in x64 but not in x86?

Posted: Sun Feb 01, 2015 11:59 pm
by T4r4ntul4
weird but its working without virusscanner. how to solve this with a virusscanner enabled?

Re: same code working in x64 but not in x86?

Posted: Mon Feb 02, 2015 4:20 am
by Bisonte
set the purebasic compiler on the whitelist.

Re: same code working in x64 but not in x86?

Posted: Mon Feb 02, 2015 2:37 pm
by T4r4ntul4
i just learned i cant do that, because i have a 64bit system...
Note:
This option is just available under 32-bit systems. If you are using a 64-bit system you should not have any kind of problems with blocked applications caused by Avira. Therefore, the following options are just valid for 32-bit systems. If you are using a 64-bit system, you do not have access to the Application filter.
source: http://www.avira.com/en/support-for-hom ... /kbid/1257


it gets weirder, if i uncheck 'enable debugger' it will just compile without problems... but without a debugger its hard to test things.

what antivirus do you use?

Re: same code working in x64 but not in x86?

Posted: Mon Feb 02, 2015 10:37 pm
by Bisonte
Avira with PB on whitelist ;)

Re: same code working in x64 but not in x86?

Posted: Mon Feb 02, 2015 11:54 pm
by T4r4ntul4
can you tell where you whitelisted it in Avira?

Re: same code working in x64 but not in x86?

Posted: Tue Feb 03, 2015 6:24 am
by applePi
i have stopped to use antivirus software from about 2 years for the reason i have explained here http://purebasic.fr/english/viewtopic.php?f=17&t=55948 . i use the virtualization instead and once you reboot your computer return clean. there is also http://www.sandboxie.com/ i havn't tried it yet. usualy my system stay in good condition even after a year. but there is no %100 complete protection , i have visited alibaba site (like ebay) searching for magnets and the next day and until now alibaba Ads about magnets every here. i don't think it is harmful but this is a proof that they can penetrate the virtualizastion , from my previous experience the things will not be better if the antitivirus/antitrojans are installed.
as to How to White List Programs in Avira : i found these links:
http://www.ehow.co.uk/how_8071941_white ... avira.html

Re: same code working in x64 but not in x86?

Posted: Tue Feb 03, 2015 1:22 pm
by T4r4ntul4
thanks for your info ApplePi, but i dont have a whitelist. i can make a exception for certain files/map structure, but thats not working. iam gonna turn off the real time protection if iam working on this. i dont see any other option right now.