English Amiga Board


Go Back   English Amiga Board > News

 
 
Thread Tools
Old 29 August 2017, 05:29   #561
NovaCoder
Registered User
NovaCoder's Avatar
 
Join Date: Sep 2007
Location: Melbourne/Australia
Posts: 3,447
Quote:
Originally Posted by ninevoltz View Post
NovaCoder,

Is there any chance you would share your source code for your SCUMMVM-RTG or ZDOOM-RTG port? (Awesome work, by the way!) Maybe at github? Only reason I ask is because they both don't work correctly at the moment with the VA2000 video card, and having the source code might be helpful in figuring out why. The video is stuck at the top third of the screen, and is badly scrambled. I'm sure it's a problem with the VA2000 drivers, because it works fine with a RetinaZ3BLT graphics card, both using P96.

Any ideas?

(Also, in case you weren't aware, your private message box is too full to accept any private messages.)
Hiya,

Yep sure, I always used the same code for my RTG games. I used the CyberGFX API to get a pointer to the video bitmap and then did a blit (memcpy) straight into it with my game's graphics.

http://amiga.sourceforge.net/amidevh...&action=Search

It's considered a 'low level' function so that's probably why the P96 emulation of this function isn't working for VA2000.

Code:
void OSystem_AmigaOS3::updateScreen() {
#ifndef NDEBUG
    debug(9, "OSystem_AmigaOS3::updateScreen()");
#endif
        
    static UBYTE* src;
    
    
    if (_mouseCursor.visible) {
        drawMouse();
    }
    
    if (_overlayVisible) {
        UBYTE *base_address;
        APTR video_bitmap_handle = LockBitMapTags(_hardwareOverlayScreen->ViewPort.RasInfo->BitMap,
        									 LBMI_BASEADDRESS, (ULONG)&base_address,
        									 TAG_DONE);										 
        if (video_bitmap_handle) {
            CopyMemQuick((UBYTE*)_overlayscreen8.pixels, base_address, (_videoMode.overlayWidth * _videoMode.overlayHeight));
        	UnLockBitMap (video_bitmap_handle);
        	video_bitmap_handle = NULL;
        }      
    } else {
        if (_currentShakePos != _newShakePos) {
            // Set the 'dirty area' to black.
            memset(_tmpscreen.getBasePtr(0, (_videoMode.screenHeight - _newShakePos)), 0, (_videoMode.screenWidth * _newShakePos)); 
            
            src = (UBYTE*)_screen.getBasePtr(0, _newShakePos);
            byte *dst = (byte*)_tmpscreen.getBasePtr(0, 0);
            
            CopyMemQuick(src, dst, (_videoMode.screenWidth * (_videoMode.screenHeight - _newShakePos)));
            
            // Reset.
	        _currentShakePos = _newShakePos;
	        
	        src = (UBYTE*)_tmpscreen.pixels;
        } else {
            src = (UBYTE*)_screen.pixels;
        }
        

        UBYTE *base_address;
        APTR video_bitmap_handle = LockBitMapTags(_hardwareGameScreen->ViewPort.RasInfo->BitMap,
        									 LBMI_BASEADDRESS, (ULONG)&base_address,
        									 TAG_DONE);
        if (video_bitmap_handle) {
            CopyMemQuick(src, base_address, (_videoMode.screenWidth * _videoMode.screenHeight));
        	UnLockBitMap (video_bitmap_handle);
        	video_bitmap_handle = NULL;
        }            
    }
    


    // Check whether the palette was changed.
	if (_paletteDirtyEnd != 0) {
        updatePalette();
	}	
    
    
    if (_mouseCursor.visible) {
        undrawMouse();
    }	
}

The only other possible problem is that the wrong screen mode is open using VA2000, this is how I open a screen in ScummVM

Code:
struct Screen* OSystem_AmigaOS3::createHardwareScreen(uint width, uint height) {

    // Create the hardware screen.
    struct Screen* screen = NULL;
    ULONG modeId = INVALID_ID;
    
	modeId = BestCModeIDTags(
        		CYBRBIDTG_Depth, CGX_VIDEO_DEPTH,
        		CYBRBIDTG_NominalWidth, width,
        		CYBRBIDTG_NominalHeight, height,
        		TAG_DONE);   


	// Verify the mode choosen.
	if (modeId != INVALID_ID) {
    	if (GetCyberIDAttr(CYBRIDATTR_DEPTH, modeId) != CGX_VIDEO_DEPTH) {
    		modeId = INVALID_ID;
    	}
    
    	if (GetCyberIDAttr(CYBRIDATTR_WIDTH, modeId) != width) {
    	   modeId = INVALID_ID;
    	}
    
    	if (GetCyberIDAttr(CYBRIDATTR_HEIGHT, modeId) != height) {
    	   modeId = INVALID_ID;
    	}
	}

	if (modeId == INVALID_ID) {
		warning("Couldn't find a Screen Mode for requested mode");
    }
    

    if (modeId != INVALID_ID) {
    	screen = OpenScreenTags(NULL,
                         SA_Depth, CGX_VIDEO_DEPTH,
                         SA_DisplayID, modeId,
                         SA_Width, width,
    					 SA_Height, height,
						 SA_Type, CUSTOMSCREEN,
                         SA_Quiet, TRUE,
    					 SA_ShowTitle, FALSE,
    					 SA_Draggable, FALSE,
                         SA_Exclusive, TRUE,
    					 SA_AutoScroll, FALSE,
						 TAG_END);
    }

    return screen;
}
NovaCoder is offline  
AdSense AdSense  
Old 18 December 2017, 01:22   #562
Foul
Registered User

Foul's Avatar
 
Join Date: Jun 2009
Location: Perigueux/France
Age: 43
Posts: 1,273
Send a message via ICQ to Foul Send a message via MSN to Foul Send a message via Skype™ to Foul
Just in time for the holidays, the final release of ScummVM 2.0 is here!

http://www.scummvm.org/

Foul is online now  
Old 25 January 2018, 13:25   #563
traxx
Registered User
 
Join Date: Aug 2017
Location: Jyväskylä / Finland
Posts: 10
Just tried to install ScummVM_AGA_030 (newest version 1.5.0.004) from Aminet on my Amiga1200 (with ACA1233n) but only get this grey screen when starting it and about 10 second later it changes to that another weird screen and finally shows ”software failure” screen. I'm runninh ClassicWB 3.9

Also tried reinstalled AHI 4.18 (actually correct version was already installed) for sure and set it to 14bit fast stereo -mode but no affect when launching the ScummVM.

And yes I fullfill the requirements: Amiga 1200 with 68030 accelerator (ACA-1233n which has 128MB fastram) and original 3.1 ROM's.

Video what happens [ Show youtube player ]

Any ideas what is wrong and what to do?
traxx is offline  
Old 28 January 2018, 07:25   #564
NovaCoder
Registered User
NovaCoder's Avatar
 
Join Date: Sep 2007
Location: Melbourne/Australia
Posts: 3,447
Quote:
Originally Posted by traxx View Post
Just tried to install ScummVM_AGA_030 (newest version 1.5.0.004) from Aminet on my Amiga1200 (with ACA1233n) but only get this grey screen when starting it and about 10 second later it changes to that another weird screen and finally shows ”software failure” screen. I'm runninh ClassicWB 3.9

Also tried reinstalled AHI 4.18 (actually correct version was already installed) for sure and set it to 14bit fast stereo -mode but no affect when launching the ScummVM.

And yes I fullfill the requirements: Amiga 1200 with 68030 accelerator (ACA-1233n which has 128MB fastram) and original 3.1 ROM's.

Video what happens [ Show youtube player ]

Any ideas what is wrong and what to do?
Make sure you aren't running the CyberBugFix hack.

Also check for an error.txt file in the game install directory.

Finally, make sure that AHI Prefs opens without any error messages.
NovaCoder is offline  
Old 28 January 2018, 21:40   #565
traxx
Registered User
 
Join Date: Aug 2017
Location: Jyväskylä / Finland
Posts: 10
Quote:
Originally Posted by NovaCoder View Post
Make sure you aren't running the CyberBugFix hack.

Also check for an error.txt file in the game install directory.

Finally, make sure that AHI Prefs opens without any error messages.
Thanks, didn’t notice that error-file earlier and now got it work with the help of that. MT-32 support is also functioning nice
traxx is offline  
AdSense AdSense  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Latest version of ScummVM also ported to ECS NovaCoder News 121 02 March 2017 14:16
Latest version of ScummVM also ported to RTG NovaCoder News 200 08 June 2016 11:39
Quake 2 ported to AGA NovaCoder News 130 22 May 2014 18:44
Full Throttle AGA - ScummVM V1.0.0 NovaCoder project.Amiga Game Factory 102 04 July 2011 12:53
ScummVM and AGA Amiga HardStep support.Games 25 05 November 2006 21:19

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 19:19.


Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Page generated in 0.18042 seconds with 13 queries