Jump to content

GreSetDefaultArcParameters: Difference between revisions

From EDM2
Created page with "GreSetDefaultArcParameters sets the arc parameters to the default values. This function is supported by the graphics engine. ==Syntax== GreSetDefaultArcParameters(hdc, pA..."
 
Ak120 (talk | contribs)
mNo edit summary
Line 1: Line 1:
GreSetDefaultArcParameters sets the arc parameters to the default values.  
GreSetDefaultArcParameters sets the arc parameters to the default values.


This function is supported by the graphics engine.  
This function is supported by the graphics engine.


==Syntax==
==Syntax==
  GreSetDefaultArcParameters(hdc, pArcParms, pInstance, lFunction);
  GreSetDefaultArcParameters(hdc, pArcParms, pInstance, lFunction)
 
==Parameters==
==Parameters==
;hdc (HDC) - input  
;hdc (HDC) - input:Device context handle.
:Device context handle.  
;pArcParms (PARCPARAMS) - input:Pointer to the default arc parameters.
 
:Pointer to an ARCPARAMS structure:
;pArcParms (PARCPARAMS) - input  
::lP P coefficient
:Pointer to the default arc parameters.  
::lQ Q coefficient
 
::lR R coefficient
:Pointer to an ARCPARAMS structure:  
::lS S coefficient
::lP P coefficient  
;pInstance (PVOID) - input:Pointer to instance data.
::lQ Q coefficient  
;lFunction (ULONG) - input:High-order WORD=flags; low-order WORD=NGreSetDefaultArcParameters.
::lR R coefficient  
::lS S coefficient  
 
;pInstance (PVOID) - input  
:Pointer to instance data.  
 
;lFunction (ULONG) - input  
:High-order WORD=flags; low-order WORD=NGreSetDefaultArcParameters.  


==Return Code==
==Return Code==
;fSuccess (BOOL) - returns  
;fSuccess (BOOL) - returns:Return codes.  
:Return codes.  
:On completion, the handling routine must return BOOLEAN (fSuccess).
 
:*TRUE Successful
:On completion, the handling routine must return BOOLEAN (fSuccess).  
:*FALSE Error
 
:Possible Errors Detected: When an error is detected, the graphics engine calls WinSetErrorInfo to post the condition. Reasons for failure of this function include:
:*TRUE Successful  
:*PMERR_HDC_BUSY
:*FALSE Error  
:*PMERR_INV_HDC
 
:Refer to the "Error Explanations" section of the Presentation Manager Programming Reference for further explanation.
:Possible Errors Detected:   When an error is detected, the graphics engine calls WinSetErrorInfo to post the condition. Reasons for failure of this function include:  
 
:*PMERR_HDC_BUSY  
:*PMERR_INV_HDC  
 
:Refer to the "Error Explanations" section of the Presentation Manager Programming Reference for further explanation.  


==Sample Code==
==Sample Code==
Line 51: Line 38:
BOOL          fSuccess;  /*  Return codes. */
BOOL          fSuccess;  /*  Return codes. */


fSuccess = GreSetDefaultArcParameters(hdc,
fSuccess = GreSetDefaultArcParameters(hdc, pArcParms, pInstance, lFunction);
            pArcParms, pInstance, lFunction);
 
</PRE>
</PRE>


[[Category:Gre]]
[[Category:Gre]]

Revision as of 09:28, 5 April 2025

GreSetDefaultArcParameters sets the arc parameters to the default values.

This function is supported by the graphics engine.

Syntax

GreSetDefaultArcParameters(hdc, pArcParms, pInstance, lFunction)

Parameters

hdc (HDC) - input
Device context handle.
pArcParms (PARCPARAMS) - input
Pointer to the default arc parameters.
Pointer to an ARCPARAMS structure:
lP P coefficient
lQ Q coefficient
lR R coefficient
lS S coefficient
pInstance (PVOID) - input
Pointer to instance data.
lFunction (ULONG) - input
High-order WORD=flags; low-order WORD=NGreSetDefaultArcParameters.

Return Code

fSuccess (BOOL) - returns
Return codes.
On completion, the handling routine must return BOOLEAN (fSuccess).
  • TRUE Successful
  • FALSE Error
Possible Errors Detected: When an error is detected, the graphics engine calls WinSetErrorInfo to post the condition. Reasons for failure of this function include:
  • PMERR_HDC_BUSY
  • PMERR_INV_HDC
Refer to the "Error Explanations" section of the Presentation Manager Programming Reference for further explanation.

Sample Code

#define INCL_GRE_DEVSUPPORT
#include <os2.h>

HDC           hdc;        /*  Device context handle. */
PARCPARAMS    pArcParms;  /*  Pointer to the default arc parameters. */
PVOID         pInstance;  /*  Pointer to instance data. */
ULONG         lFunction;  /*  High-order WORD=flags; low-order WORD=NGreSetDefaultArcParameters. */
BOOL          fSuccess;   /*  Return codes. */

fSuccess = GreSetDefaultArcParameters(hdc, pArcParms, pInstance, lFunction);