ugBASIC 1.18
An isomorphic BASIC language compiler for retrocomputers
Loading...
Searching...
No Matches
fade_in.c
Go to the documentation of this file.
1/*****************************************************************************
2 * ugBASIC - an isomorphic BASIC language compiler for retrocomputers *
3 *****************************************************************************
4 * Copyright 2021-2024 Marco Spedaletti (asimov@mclink.it)
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 *----------------------------------------------------------------------------
18 * Concesso in licenza secondo i termini della Licenza Apache, versione 2.0
19 * (la "Licenza"); è proibito usare questo file se non in conformità alla
20 * Licenza. Una copia della Licenza è disponibile all'indirizzo:
21 *
22 * http://www.apache.org/licenses/LICENSE-2.0
23 *
24 * Se non richiesto dalla legislazione vigente o concordato per iscritto,
25 * il software distribuito nei termini della Licenza è distribuito
26 * "COSÌ COM'È", SENZA GARANZIE O CONDIZIONI DI ALCUN TIPO, esplicite o
27 * implicite. Consultare la Licenza per il testo specifico che regola le
28 * autorizzazioni e le limitazioni previste dalla medesima.
29 ****************************************************************************/
30
31/****************************************************************************
32 * INCLUDE SECTION
33 ****************************************************************************/
34
35#include "../../ugbc.h"
36
37/****************************************************************************
38 * CODE SECTION
39 ****************************************************************************/
40
41#if !(defined(__pc128op__) || defined(__mo5__) || defined(__to8__))
42
46
47/* <usermanual>
48@keyword FADE IN
49
50@english
51
52The ''FADE IN'' command is a fundamental tool for creating smooth visual
53transitions, allowing you to gradually modulate the visibility of elements.
54
55This command, in its basic form ''FADE IN'', triggers a fade-in. If an element
56was previously invisible or partially transparent, this command will gradually
57make it more opaque until it reaches its full visibility.
58
59Again, the speed of the transition is usually governed by preset parameters.
60An interesting variant of the ''FADE IN'' command appears in the syntax
61''FADE IN'' palette, which finds application in scenarios where color management
62is done via palettes, typically in low-resolution graphic contexts or with a
63limited number of available colors. Instead of acting on opacity, this command
64initiates a gradual transition between an initial color palette and the specified
65palette, making the image emerge through a progressive transformation of its colors.
66
67It is possible to combine this palette-based fade with a specific time duration
68using the syntax ''PERIOD time'', where time defines the time frame within which
69the color transition from the initial palette to the desired one must be
70completed. Finally, for direct control over the duration of the opacity-based
71fade-in, the form ''FADE IN PERIOD time'' is used.
72In this syntax, the time parameter specifies the duration of the animation,
73determining the speed at which the element transitions from invisibility (or
74partial transparency) to full visibility.
75
76Using these different forms command allows you to precisely orchestrate
77visual transition effects, contributing significantly to the quality and
78fluidity of the user experience in interactive applications.
79
80@italian
81
82Il comando ''FADE IN'' è uno strumento fondamentale per creare transizioni
83visive fluide, consentendo di modulare gradualmente la visibilità degli elementi.
84
85Questo comando, nella sua forma base ''FADE IN'', attiva una dissolvenza in entrata. Se un elemento
86era precedentemente invisibile o parzialmente trasparente, questo comando lo renderà gradualmente
87più opaco fino a raggiungere la sua piena visibilità.
88
89Anche in questo caso, la velocità della transizione è solitamente regolata da parametri preimpostati.
90Un'interessante variante del comando ''FADE IN'' appare nella sintassi
91''palette FADE IN'', che trova applicazione in scenari in cui la gestione del colore
92viene effettuata tramite palette, tipicamente in contesti grafici a bassa risoluzione o con un
93numero limitato di colori disponibili. Invece di agire sull'opacità, questo comando
94avvia una transizione graduale tra una palette di colori iniziale e quella specificata, facendo emergere l'immagine attraverso una progressiva trasformazione dei suoi colori.
95
96È possibile combinare questa dissolvenza basata sulla palette con una durata temporale specifica
97utilizzando la sintassi ''PERIOD time'', dove ''time'' definisce l'intervallo di tempo entro il quale
98deve essere completata la transizione di colore dalla palette iniziale a quella desiderata. Infine, per un controllo diretto sulla durata della dissolvenza in entrata basata sull'opacità,
99viene utilizzata la sintassi ''FADE IN PERIOD time''.
100In questa sintassi, il parametro time specifica la durata dell'animazione,
101determinando la velocità con cui l'elemento passa dall'invisibilità (o
102dalla trasparenza parziale) alla piena visibilità.
103
104L'utilizzo di queste diverse forme di comando consente di orchestrare con precisione
105gli effetti di transizione visiva, contribuendo in modo significativo alla qualità e
106alla fluidità dell'esperienza utente nelle applicazioni interattive.
107
108@syntax FADE IN [palette] [PERIOD time]
109
110@example FADE IN
111@example FADE IN PERIOD 10
112
113@seeAlso FADE OUT
114@target atari
115@target atarixl
116@target pc128op
117@target mo5
118@target to8
119</usermanual> */
120
121void fade_in( Environment * _environment, char * _period ) {
122
123}
124
125#endif
void fade_in(Environment *_environment, char *_period)
Emit code for FADE.
Definition fade_in.c:47
struct _Environment Environment
Structure of compilation environment.