Introduction

Food packaging, a crucial element of any product from the consumer perspective, is important to modern commercial trade [1, 2]. Traditional food packaging based on petroleum derivatives is vital for maintaining the quality and safety of food products during storage and transportation. However, the widespread use of petroleum-based plastic packaging has become a major global concern because its production and disposal present many environmental problems [3]. Natural biopolymers (e.g., proteins, lipids, and polysaccharides) have emerged as potential environmentally friendly substitutes for plastic packaging materials due to their low cost, durability, effective barrier function, and mechanical properties [4,5,6]. Starch is a natural, renewable biopolymer found in many plants. moreover, it is inexpensive, safe, abundant, edible, and biodegradable [7]. However, starch has some undesirable physical characteristics such as strong hydrophily and retrogradation, which limit its use in food packaging. A previous study indicated that these disadvantages can be overcome by adding small quantities of compounds such as glycerol or biopolymers [8]. Carrageenan, a natural polysaccharide sulfate composed of galactose and dehydrated galactose, is extensively utilized in food and pharmaceutical applications. It is also a strong candidate for water adsorption applications and has been employed in water treatment applications, either alone or in combination with other polymers due to its biodegradability, accessibility, water solubility, availability of functional groups [9]. It has been demonstrated that carrageenan has a reinforcing effect in starch-based films [10]. In recent years, with the increasing concern about food safety, plenty efforts have been paid on the development of intelligent films incorporated with pH indicators, which can monitor food freshness through the visible color variation of pH indicators [11]. In earlier research, chemical indicators such as bromothymol blue and bromothymol green have been used for food freshness monitoring because of their rapid color response performance [11, 12]. However, the potential toxicity of chemical indicators may cause food safety problems [12, 13], therefore, intensive efforts have been devoted to the development of natural pigments, like betalain, anthocyanin, and curcumin. Among these natural pigments, anthocyanins have been preferred as ideal indicator materials because of their broad pH responsiveness [11]. Currently, starch based films incorporated with anthocyanins of different varieties are being utilized to monitor food freshness. For instance, Zong et al. [14] used starch, gelatin and purple sweet potato anthocyanins to create a pH-sensitive intelligent packaging films aimed at monitoring the freshness of Flammulina velutipes mushroom. Similarly, Jiang et al. [15] developed a valuable tool for intelligent food packaging using starch, carrageenan and Oxalis triangularis anthocyanins to monitor fish freshness. Cao et al. [16] also reported on a colorimetric and antioxidant film made from cassava starch, carrageenan and black nightshade fruit anthocyanins, demonstrating its potential as a pH indicator for Cyclina sinensis freshness.

Rosa chinensis (Chinese rose), as an important ancestor of modern rose, is widely distributed in Jiangsu, Shandong, and Hebei provinces [17]. The flowers are beautiful with different colors (purplish red or pale purplish red or pink), which are influenced by kinds of flavonoids and the pH environments. Till now, anthocyanin isolated from rose petals has been incorporated into different biopolymer-based matrix to develop pH-responsive smart films and the mechanical strength of films has been greatly enhanced after the introduction of anthocyanin-rich rose extract [18, 19]. However, few studies have considered the development of food packaging films using R. chinensis flower anthocyanins. In this study, anthocyanins were extracted from R. chinensis flowers and blended with maize starch/carrageenan to yield starch-based active food packaging films. Physico-chemical and functional properties of the developed films were then assessed to evaluate their potential for application in the food packaging industry.

Materials and methods

Materials and reagents

Fresh R. chinensis flowers were obtained in April 2023 from Xincheng Forest Park in Huaian, China. The flowers were transported to the laboratory within 2 h, cleaned with distilled water, and stored at \(-18\,^{\circ }\hbox {C}\) until use. Carrageenan (CG) and maize starch (MS) with molecular weights (Mw) of approximately 300,000 and 180,000, respectively were purchased from Jiangsu Shanglian Supermarket Co., Ltd. (Huaian, China). 2,2-diphenyl-1-picrylhydrazyl was obtained from Huaian Kaitong Chemical Reagent Co., Ltd. (Huaian, China). All other reagents were of analytical grade.

Anthocyanin extraction

Anthocyanins were extracted from fresh flowers of R. chinensis by using the conventional solid–liquid extraction method reported by Wang et al. [20] with minor modifications. Briefly, 200 g of raw material was ground and immersed in 1.5 L of 80% (v/v) ethanol solution containing 1.5% HCl to stabilize the anthocyanins. Next, the extraction process was conducted three times at \(5\,^{\circ }\hbox {C}\) for 12 h to completely extract the anthocyanins. The extract solution was centrifuged at 4000 rpm for 20 min and filtered to remove non-hydrophilic segments. The filtrate was further purified on the column of AB-8 macroporous resin, which was continuously eluted with 80% ethanol solution containing 0.5% HCl (v/v). The resulting supernatant was concentrated at \(30\,^{\circ }\hbox {C}\) using a rotary evaporator to obtain the R. chinensis flower extract (RFE) solution. The total anthocyanin content of the RFE solution was determined using a pH-differential assay. The RFE solution was stored in the dark at approximately \(5\,^{\circ }\hbox {C}\) until use.

Preparation of films

We dissolved 4.5 g of MS and 30% of CG and glycerol on basis of MS in 120 mL of distilled water and heated the mixture for 30 min at \(95\,^{\circ }\hbox {C}\) to obtain a gelatinized MS blend. The mixture was cooled below \(35\,^{\circ }\hbox {C}\), and then 0, 1.2, 2.4 and 3.6 mL/g of RFE solution on MS basis with a total anthocyanin content of 0.12 mg/mL was added and the mixture was continuously stirred for 1 h. The resulting blends containing RFE solution were labeled as MS-CG-RFE-A, MS-CG-RFE-B and MS-CG-RFE-C. In the same procedure, an MS blend was made by using 1.25 g of glycerol, 5.85 g of MS and 150 mL of water. The blend was degassed and poured on an acrylic plate (\(24\hbox { cm} \times 24\hbox { cm}\)), and heated for 24 h in a water bath at \(35\,^{\circ }\hbox {C}\). Prior to analysis, all films were put into desiccators at \(20\,^{\circ }\hbox {C}\) and 50% relative humidity for 72 h to equilibrate.

Determination of film physical properties

Thickness and water content

Each film was sliced into \(2\hbox { cm} \times 2\hbox { cm}\) strips, and its thickness was measured in five places using a digital micrometer with 0.001-mm accuracy. Film samples weighing approximately 0.3 g were dried in an oven at 105\(\,^{\circ }\hbox {C}\) until constant weight was reached. The water content of each film sample was calculated as follows:

$$\begin{aligned} \text {Water content } (\%)=\frac{M_{\textrm{i}}-M_{\textrm{t}}}{M_{\textrm{i}}}\times 100 \end{aligned}$$
(1)

where M\(_i\) and M\(_t\) are the original and final weights of the film sample, respectively.

Water vapor permeability

A 50-mL centrifuge tube was filled with 40 g of anhydrous silica gel and sealed with a film sample (\(5\hbox { cm} \times 5\hbox { cm}\)). The tube was then maintained at 20\(\,^{\circ }\hbox {C}\) in a desiccator at 100% relative humidity and weighed every 24 h for 7 days. WVP was calculated as follows:

$$\begin{aligned} WVP={\frac{W\times x}{t\times A\times \Delta P}} \end{aligned}$$
(2)

where W is the weight gain of the tube (g), x is the film thickness (m), t is time (s), A is the permeation area (\(\hbox {m}^{2}\)), and \(\Delta\)P is the saturated vapor pressure at \(20\,^{\circ }\hbox {C}\).

Water contact angle

Water contact angles of films were obtained using a sessile drop method with a Dataphysics OCA-20 contact angle analyser. Initially, 4 uL of distilled water droplet from micro syringe was dispensing over the membrane surface, and images was recorded within 5 s with a digital camera. The experiment was repeated at 3 times in different positions and the average value was taken.

Optical properties

Film color parameters were determined using a portable colorimeter (Color Reader CR-10; Konica Minolta, Tokyo, Japan). The color change (\(\Delta\)E) of film samples was calculated as follows:

$$\begin{aligned} \Delta E\ =\left[ (\Delta L)^{2}+(\Delta a)^{2}+(\Delta b)^{2}\right] ^{\frac{1}{2}} \end{aligned}$$
(3)

Where \(\Delta\)L, \(\Delta\)a, and \(\Delta\)b are difference between each color value of active and control films; films appeared to have the same color when \(\Delta\)E less than 2.3 and different colors when \(\Delta\)E was higher than 2.3. Transmission spectra of film samples were determined for the range 200-700 nm using a UV-3600 spectrophotometer (Shimadzu, Kyoto, Japan). Film opacity was calculated as follows:

$$\begin{aligned} \textrm{Opacity}={\frac{Abs_{600}}{x}} \end{aligned}$$
(4)

where x is the film thickness and \(\hbox {Abs}_{600}\) is the absorbency of the film at 600 nm.

Thermogravimetric property

Thermogravimetric properties were measured using a Netzsch TG 209 apparatus at \(20-800\,^{\circ }\hbox {C}\) under a 20 mL/min nitrogen flow.

Mechanical properties

Mechanical properties were evaluated using Chinese National Standard method GB/T 1040.3-2006. The films were divided into strips (\(4\hbox { cm} \times 1\hbox { cm}\)) and their tensile strength (TS) and elongation at break (EAB) were determined using a CT3 Texture Analyzer (Brookfield Engineering, Middleboro, MA, USA) at a strain rate of 1 mm/s at \(25\,^{\circ }\hbox {C}\).

Determination of film functional properties

DPPH scavenging activity

DPPH scavenging activity of film samples was determined by putting different amount of films (0-20 mg) in \(100\, \upmu \hbox {M}\) DPPH ETOH solution (4 mL) and reacting for 2 h at \(4\,^{\circ }\hbox {C}\). The film DPPH scavenging activity was calculated by the following formula:

$$\begin{aligned} \text {DPPH scavenging activity } (\%)=\frac{A_{\textrm{0}}-A_{\textrm{1}}}{A_{\textrm{0}}}\times 100 \end{aligned}$$
(5)

where A\(_0\) and A\(_1\) were the absorbance of blank and reaction solution at 517 nm, respectively.

pH response sensitivity and stability

The pH response sensitivity and stability of films were evaluated by submerging the film (\(2\hbox { cm} \times 2\hbox { cm}\)) in various buffer solutions for different times. The color variation of the films was captured using a digital camera.

Ammonia sensitivity

The ammonia sensitivity of films was determined by fixing the film (\(2\hbox { cm} \times 2\hbox { cm}\)) in the 1-cm headspace above 15 mL of 0.1 M ammonia solution for 10-50 min. A CR-10 colorimeter (Konica Minolta) was used to record the film color characteristics every 10 min.

Structural characterization

The films’ fracture morphology was observed using Phenom Pro scanning electron microscope (SEM) (Phenom World, Netherlands) at 1500 magnification and 5.0 kV accelerating voltage. The films’ Fourier transform infrared (FT-IR) spectrum was obtained on a Thermo Nicolet 5700 FT-IR spectrometer (Thermo Nicolet Corporation, Wisconsin, USA) at the frequency ranging from \(4000 \hbox { cm}^{-1}\) to \(650 \hbox { cm}^{-1}\). The X-ray diffraction (XRD) pattern of films was identified using a D8 Advance diffractometer with Ni-filtered Cu K\(\upalpha\) radiation from \(5\,^{\circ }\) to \(80\,^{\circ }\).

Application of films

The MS-CG and MS-CG-RFE films were used to monitor pork freshness based on a methodology described elsewhere with some modifications [21]. Fresh pork (30 g) was packed in a 1.5-L transparent plastic box. Film strips (1 cm \(\times\) 2 cm) were fixed in the headspace of the box without directly contacting the pork, sealed with a lid, and stored at 20\(\,^{\circ }\hbox {C}\) for 72 h. At various times throughout this period, the color of the film samples was recorded using an optical scanner. We also determined the total volatile basic nitrogen (TVB-N) as an indicator of freshness/spoilage using the Kjeldahl method, following Chinese National Standard method GB 5009.228-2016.

Statistical analysis

All data are presented in the form of mean ± standard deviation (SD). The SPSS 13.0 program was used to do the Duncan test and one-way analysis of variance (ANOVA). If p less than 0.05, the results were judged statistically different.

Results

Anthocyanin content

The anthocyanin content of fresh R. chinensis flowers were tested using the pH differential method. The anthocyanin content on basis fresh weight was 1.45 ± 0.32 mg/g. The anthocyanin content of red lettuce and red terebinth were reported to be 0.05 mg/g and 0.035 mg/g, repectively [22, 23]. The anthocyanin content might be influenced by extraction conditions and plant sources. Our result indicates that R. chinensis flowers are rich in anthocyanins and therefore suitable for use as a natural additive in active food packaging.

Film’s physical features

Thickness and water content

As displayed in Table 1, the MS, MS-CG and MS-CG-RFE films varied in thickness from 0.063 to 0.092 mm. The thickness of the MS film was enhanced by the addition of CG and/or RFE (p less than 0.05). The thicknesses of the MS-CG-RFE-A and MS-CG-RFE-B films did not differ significantly (p was higher than 0.05), whereas the MS-CG-RFE-C film was significantly thicker than the MS-CG-RFE-A film (p less than 0.05). These results are likely due to higher anthocyanin contents disrupting the matrix structures of the films, increasing their thickness [24]. A similar result was obtained for chitosan film combined with black soybean seed coat extract [25].

Table 1 Physical properties of MS, MS-CG and MS-CG-RFE films

No significant difference was found in water content between the MS-CG and MS-CG-RFE films (p was higher than 0.05; Table 1). In contrast, the MS-CG-RFE films had significantly higher water content than the MS film (p less than 0.05), possibly due to the hydrophilic characteristics of anthocyanins [26]. With the addition of RFE, more polarized sites may have been available to absorb moisture from the environment, resulting in higher water content in the MS-CG-RFE films [27]. Among the three MS-CG-RFE films, MS-CG-RFE-B had the highest water content (14.12%). Overall, the compositions and amounts of anthocyanins in the extracts had a significant impact on the water content of MS-CG-RFE films.

Water vapor permeability

The WVP values of the MS, MS-CG and MS-CG-RFE films are provided in Table 1. The WVP of the MS and MS-CG films was in the range of 2.13 to \(2.61 \times 10^{-10}\hbox { g }\hbox {m}^{-1}\) \(\hbox {s}^{-1}\hbox { Pa}^{-1}\). The MS-CG film had a higher WVP than the MS film (p less than 0.05), indicating that the WVP of MS film was increased by the introduction of CG. WVP did not differ significantly between the MS-CG and MS-CG-RFE-A films (p was higher than 0.05); however, the WVPs of the MS-CG-RFE-B and MS-CG-RFE-C films were significantly lower than that of the MS-CG film (p less than 0.05). The MS-CG-RFE-B film, with an RFE addition of 2.4 mL/g, had the lowest WVP (\(2.16 \times 10^{-10}\hbox { g } \hbox {m}^{-1} \hbox { s}^{-1} \hbox { Pa}^{-1}\)). This result suggested that RFE could improve the water vapor barrier function of MS-CG films. It was possible that the lower WVPs in the MS-CG-RFE films were caused by dense networks created by intermolecular interactions between anthocyanins and MS/CG. Similar findings were reported in a previous study [20].

Fig. 1
figure 1

Water contact angles of films

Water contact angles

The WCA was employed to evaluate the wettability of the membrane’s surface. High WCA is associated with hydrophobic nature, whilst low WCA is associated with hydrophilic nature [28]. The effect of the incorporation of CG and different concentrations of RFE on the WCA of the MS film is shown in Fig. 1. The WCA of the MS film (96.7\(\,^{\circ }\)) higher than that of the cassava starch film (66.42\(\,^{\circ }\)) [29]. The increase in WCA might be due to a increased roughness of the MS film surface, which promoted the surface hydrophobicity of the film. The WCA was drastically decreased with the addition of CG and RFE, which might be resulted from the hydrophilicity of CG and anthocyanins existing in RFE. The WCA of the MS-CG and MS-CG-RFE films was less than 90\(\,^{\circ }\), indicating their hydrophilic nature. The results agreed with that of Liu et al. [30] who believed that WCA of the composite film was not only related to the surface hydrophobicity of the film, but also affected by the surface roughness and porosity of the film.

Optical properties

The color parameters of the MS, MS-CG, and MS-CG-RFE films are listed in Table 2. The MS and MS-CG films were visually transparent, whereas the MS-CG-RFE films turned yellow. The L, a, b and \(\Delta\)E values of the films were measured using a white plate as a blank control. The \(\Delta\)E values of the MS and MS-CG films were 0.88 and 1.27 (less than 2.3) respectively (Table 2), indicating non-significant differences in color. The unchanged color of the MS-CG film was attributable to the transparency and colorlessness of CG [10]. The MS-CG-RFE film had higher a and b values and lower L values than the MS and MS-CG films (p less than 0.05), indicating that the MS-CG-RFE films shifted toward dark red and yellow coloration. Adding RFE substantially altered the color of the MS-CG film, probably due to the high anthocyanin concentration. In addition, the color difference (\(\Delta\)E) was significantly (p less than 0.05) affected by the incorporation of RFE, and the \(\Delta \hbox {E}\) values of MS-CG-RFE films was decreased as the added amount of RFE increased from 2.4 mL/g to 3.6 mL/g. Prietto et al. [31] found that maize starch films had negative b values after the incorporation of red cabbage anthocyanins, whereas films incorporating black bean anthocyanins had positive b values. Our results indicated that the color of anthocyanin-rich films was impacted by the added biopolymer, as well as by the composition and quantity of the polyphenols.

Fig. 2
figure 2

UV–vis light transmittance (A), TGA (B), DTG (C), DPPH radical scavenging activity (D) of films

Table 2 Color values of MS, MS-CG and MS-CG-RFE films

The transparency characteristics of the MS, MS-CG and MS-CG-RFE films for a wavelength range of 200-700 nm are shown in Fig. 2-A. In the absence of ultraviolet (UV)-visible light absorption groups, the MS film demonstrated the greatest light transmittance in the UV–visible wavelength range (200-700 nm) compared to the other films [32]. In contrast, adding CG to the MS film drastically decreased its ability to transmit light. This result may have been caused by CG throughout the film matrix scattering or obstructing light transmission [10]. Compared to the MS-CG film, the light transmittance of the MS-CG-RFE-A film was weaker in the UV–visible wavelength range (430–700 nm), perhaps due to either light scattering or obstruction by RFE particles distributed in the film matrix or the strong UV–visible radiation absorption properties of polyphenols in RFE [33]. In the wavelength range of 200-700 nm, the light transmittance of the MS-CG-RFE-A film was greater than that of the MS-CG-RFE-B and MS-CG-RFE-C films. In general, light transmittance is inversely associated with the capacity of the film to block light [32]. Active packaging films with excellent light-blocking properties can effectively shield the packaged food from nutrient losses, color changes, and off-flavor development. Our findings indicated that the UV–visible light barrier property of the MS film was considerably enhanced by the addition of CG and RFE. At least one study has reported that the light-blocking properties of MS film were increased when supplemented with anthocyanins extracted from roselle (Hibiscus sabdariffa) flowers in Jamaica [34]. The opacity values for each film are also listed in Table 1. The MS film had a low opacity value (0.48 \(\hbox {mm}^{-1}\)), indicating high transparency. Compared to the MS film, the MS-CG-RFE films displayed opacity values ranging from 2.83 to 4.78 \(\hbox {mm}^{-1}\). In general, the opacity of MS-CG-RFE films increased with increasing RFE content, which was attributable to the light scattering ability of anthocyanins within the film. Similar results were observed in a previous study [20].

Thermal property

As shown in Fig. 2B, C, three stages of weight loss were shown on the TGA curve for each film. The fist stage was at \(117-159\,^{\circ }\hbox {C}\), showing a weight loss of 6.01\(-\)7.19%, which was due to the evaporation of absorbed or hydrogen-bonding water in the film [21], The second stage (\(205-233\,^\circ \hbox {C}\)) with weight loss of 10.12\(-\)12.31% was associated with the glycerol decomposition [35]. The third stage of weight loss was at \(259-346\, ^\circ \hbox {C}\), related to the removal of polyhydroxyl groups from starch, as well as the depolymerization and disintegration of the film matrix [36]. When temperature reached \(800\,\,^{\circ }\hbox {C}\), the residual weight ratio of MS, MS-CG and three MS-CG-RFE films was 8.95%, 14.26%, 15.77%, 16.84% and 13.33%, respectively. At \(800\,\,^{\circ }\hbox {C}\), MS-CG and MS-CG-RFE films had larger percentage of residual mass than MS film, suggesting the temperature stability of MS-CG and MS-CG-RFE films was enhangced after the addition of CG or RFE (Fig. 2B). Prietto et al. [31] found that the control film without the added anthocyanins was completely thermally degraded. In our study, RFE slightly enhancing the thermal stability of MS-CG film was partly because of intermolecular interactions formed among MS, CG and RFE [37]. Furthermore, incorporation of CG and RFE did not change \(\hbox {MC}_{100}\) and \(\hbox {T}_{90}\) of the MS-CG-RFE films, indicating MS-CG-RFE films were stable when the test temperature was less than 100\(\,^{\circ }\hbox {C}\) [38]. The DTG peak maximum of the MS film was \(316\,^{\circ }\hbox {C}\), which was higher than that of the MS-CG or MS-CG-RFE films (\(285-296\,^{\circ }\hbox {C}\)) (Fig. 2C). The findings suggested that the addition of CG and RFE could modify the MS film’s thermal characteristics as well as the way moisture interacts with the starch matrix [39, 40].

Mechanical property

TS and EAB are two important mechanical properties of food packaging films. Table 1 depicts the TS and EAB of the composite films. The MS film showed a TS of 45.48 MPa. The TS of MS-CG film was significantly decreased, reaching a lower value of 24.1 MPa. The decreased TS in the MS-CG film might be due to the disruption of interactions between glycerol and MS by the CG molecules. The MS-CG-RFE-A film showed significantly higher TS than the MS-CG film (p less than 0.05), which was due to abundant hydroxyl groups in anthocyanins could form hydrogen bonds with the hydroxyl groups in starch, resulting in stronger interfacial adhesion between MS, CG and anthocyanins [41]. The MS-CG-RFE-A and MS-CG-RFE-B films showed lower TS than MS-CG-RFE-A film (p less than 0.05). This was probably because high contents of anthocyanins could form agglomerates, which disrupted the compactness of starch network [41]. Similar results were reported for chitosan films incorporating grape seed extracts and carvacrol [26], although CG incorporation significantly improved the TS of starch film in another study [42]. These conflicting results suggest that the TS of CG-supplemented film is affected by the nature and abundance of the film matrix components. The effects of CG and RFE on the EAB of MS film are also summarized in Table 1. There was no significant difference in EAB between the MS and MS-CG films (p was higher than 0.05), demonstrating that CG inclusion had no effect. The incorporation of RFE significantly boosted the EAB of both the MS and MS-CG films (p less than 0.05), through decreased intermolecular interactions between nearby macromolecules and the promotion of polymer chain mobility.

Functional properties of films

DPPH scavenging activity

The DPPH scavenging activity of MS-CG and MS-CG-RFE films is given in Fig. 2D, The DPPH scavenging activity for MS-CG was not changed significantly when the film concentration was increased (p less than 0.05). However, the DPPH scavenging activity of the MS-CG-RFE films significantly enhanced (p less than 0.05) with the increase of film concentration. At 4 mg/mL of films, the DPPH scavenging ability of MS-CG-RFE-A, MS-CG-RFE-B and MS-CG-RFE-C films was 16%, 49.52% and 71.72%, respectively. The MS-CG-RFE-C film with the highest RFE addition amount of 3.6 mL/g showed the maximum DPPH scavenging ability, which was approximately ten times than that of the MS-CG film. The antioxidant ability of MS-CG-RFE films was mainly attributed to the polyphenols released from film matrix, which could capture free radicals by donating phenolic hydrogen atoms. Amensour et al. [43] found that most plant extracts were capable of scavenging DPPH radicals. The results suggested that incorporation of RFE into MS-CG film enhanced antioxidant activity of the film and MS-CG-RFE films had the potential to be used as an antioxidant packaging material in the food industry.

pH response sensitivity and stability

The pH response sensitivity of the MS-CG and MS-CG-RFE films is shown in Fig. 3A. The color of MS-CG film was nearly unaltered after being submerged in several buffer solutions at pH 2-12 (Fig. 3A). However, the MS-CG-RFE films responded differently to different buffer solutions. MS-CG-RFE-A, which contained a low amount of RFE, was brighter yellow and did not exhibit a visible color change at pH 2-12. With increasing RFE content, the color change became visibly noticeable. The MS-CG-RFE-C film was red at pH 2, brown at pH 3-4, yellow at pH 5-7, green at pH 8-10, and dark red at pH 11-12. The MS-CG-RFE films containing anthocyanins displayed distinct color variation at different pH levels, was associated with the structural transformation from flavylium cation (red) and hemiketal (color less) under acidic conditions to quinone (aquamarine and green) base under alkaline environments. Similar pH sensitivity and color responses of films incorporated with plant extracts rich in anthocyanins have also been reported in some recent literature [44]. To determine the pH response stability of films, the film sample was submerged in buffer solutions at pH 2, 7 and 12, respectively for different times (10 min, 60 min and 12 h), and its color was captured using a mobile phone camera. As shown in Fig. 3B, in neutral environment, the color of the MS-CG and MS-CG-RFE films was faded into gray at the storage time of 10 min, and then kept unchanged with the storage time prolonged from 60 min to 12 h. In the acidic or alkaline condition, the color of the MS-CG film was kept colorless, however, the MS-CG-RFE films showed remarkable color changes at different storage times. In acidic condition (pH 2), the color of the MS-CG-RFE film was pink at a storage time of 10 min, and gradually deepened with the increased storage time (10-60 min) and was unchanged for 12 h. In alkaline condition (pH 12), the color of the MS-CG-RFE film turned to be green at a storage time of 10 min, and gradually deepened with the increased storage time (10-60 min) and did not change until at a storage time of 12 h. Among the three MS-CG-RFE films, the MS-CG-RFE-C film showed the most prominent color alteration under different storage times in different pH condition due to the highest RFE addition amount. The results demonstrated that the color response of MS-CG-RFE films was stable in different pH environment, which was necessary for a good candidate as a fresh indicator.

Fig. 3
figure 3

The pH response sensitivity (A) and stability (B) of films

Ammonia sensitivity

When suspended above an ammonia solution, the MS-CG film displayed non-significant color changes after various experimental durations (10-50 min), with \(\Delta\)E remaining below 2.3 (Table 3). The L value of the MS-CG film decreased with increasing RFE addition, indicating a shift toward darker coloration (p less than 0.05). The MS-CG-RFE films showed no significant differences in a, b, or \(\Delta\)E after 10 min of exposure to ammonia gas, indicating no significant color change. As ammonia exposure increased from 20 to 50 min, the MS-CG-RFE films changed from yellow to green as a result of an alkaline microenvironment shift caused by the reaction of water and ammonia within the films [21]. Notably, in a given ammonia environment, the MS-CG-RFE films displayed more vibrant coloration than the MS-CG films. Among the MS-CG-RFE films, MS-CG-RFE-C, which had the highest RFE content, exhibited the most noticeable color shifts in response to ammonia, indicating that MS-CG-RFE-C film was suitable for using as intelligent films in food packaging to track volatile nitrogen produced from food spoilage.

Table 3 Color changes of MS-CG and MS-CG-RFE films in \(\hbox {NH}_3\) for different times

Structural characterization of films

FT-IR

By using FT-IR spectroscopy, the molecular interactions that were present in the films were evaluated (Fig. 4-A). MS film showed the characteristic bands of starch: \(1079 \hbox { cm}^{-1}\) (pyranose ring of glucose), \(1642 \hbox { cm}^{-1}\) (bound water), \(2927 \hbox { cm}^{-1}\) (C-H stretching) and \(3330 \hbox { cm}^{-1}\) (O-H stretching) [5]. The FT-IR spectrum for the MS-CG-RFE film showed a strong absorption band with a maximum at 1017 \(\hbox {cm}^{-1}\), which was resulted from aromatic ring C-H deformation, as well as bands at 1649 \(\hbox {cm}^{-1}\) corresponding to the stretching vibration of the C-C aromatic ring. The absorption band with a maximum at 1234 \(\hbox {cm}^{-1}\) was assigned to stretching of pyran rings, typical of flavonoid compounds. Bands appearing between 1339 and 1370 \(\hbox {cm}^{-1}\) were assigned to C-O angular deformations of phenols [45]. In general, the addition of RFE changed the FT-IR spectroscopy of the MS-CG film remarkably. For the MS-CG-FRE films, the O-H stretching band were intensified and shifted to 3334-3339 \(\hbox {cm}^{-1}\). According to Liu et al. [46], the similar shift of O-H stretching band was observed when the anthocyanin-rich extracts were incorporated into films. These results further suggested the intermolecular interaction between MS, CG and RFE was linked to hydrogen bonding.

SEM

By using SEM, cross-sectional morphology was used to characterize the microstructural characteristics of MS-CG and MS-CG-RFE films (Fig. 4-B). Due to the fact that MS and CG had differing densities and a tendency to separate during the production of the films, a visible boundary could be seen in the MS-CG film. Compared to the MS-CG film, the MS-CG-FRE films had much smoother cross-sectional morphology. Meanwhile, the cross-sections of MS-CG-RFE films became smoother gradually with increased RFE addition amount. Zhang et al. [32] also reported that the hydrogen bond formed between OH groups of anthocyanin and polymer molecules made the structure more continuous and dense. The outcome revealed a correlation between anthocyanins contained in the MS-CG-RFE films and their SEM property.

Fig. 4
figure 4

FT-IR (A), SEM (B) and XRD (C) of films

XRD

The XRD patterns of MS, MS-CG and MS-CG-RFE films are shown in Fig. 4-C. For the MS film, the X-ray diffraction peaks of the MS film were found at \(2\theta = 5.7\,^{\circ }\), \(17.2\,^{\circ }\), \(22.0\,^{\circ }\) and \(24.1\,^{\circ }\) [47]. However, some diffraction peaks of MS were lost and some other diffraction peak intensities were increased after CG gelatinization. This was partly because of that the crystalline region of the starch particles was destructed by heat and mechanical-stirring treatment during the MS gelatinization process. Notably, all the diffraction peaks of the MS-CG film were observed in the MS-CG-RFE films. Significant reductions in the MS-CG film’s diffraction peak intensities were found after RFE was added, which was likely due to the newly formed intermolecular hydrogen bonds between MS, CG, and the anthocyanins in RFE. However, the crystallinity of the MS-CG-FRE films was not greatly altered by incorporation of FRE, indicating FRE had weak intermolecular interactions with film matrix. Wang et al. [20] also found the film diffraction peak intensities were declined after adding the anthocyanin-rich extracts. Our findings suggested that the amount and kind of added anthocyanins might influence the crystallinity of MS films.

Table 4 The TVB-N content of pork and color of films with different storage time

Application of films

The maximum TVB-N content of fresh pork was set at 15 mg/100 g in accordance with Chinese National Standard GB 2707-2016. As shown in Table 4, pork TVB-N increased significantly over the storage period, from 17.90 mg/100 g within the first 24 h (indicating the loss of freshness), to 134.33 mg/100 g after 72 h (indicating decay onset). The color changes of the MS-CG-RFE films are shown in Table 4. The MS-CG film showed no significant difference in color, whereas the MS-CG-RFE films turned different colors at different storage times. Within the first 24 h, the MS-CG-RFE films were tan colored, turning pale yellow by 48 h, pale green by 64 h, and green by 72 h. This result indicated the color of the MS-CG-RFE films was sensitive to volatile amines produced by spoiling pork, and therefore suitable for indicating meat freshness. Among the MS-CG-RFE films, MS-CG-RFE-C showed the most significant color change, from tan to olive. Overall, our findings suggested that starch-based films could be made with an extract from R. chinensis that is high in anthocyanins for monitoring the pork freshness.

Conclusion

Antioxidant and intelligent films were successfully prepared by adding 30% of CG and RFE with different amounts (1.2 mL/g, 2.4 mL/g and 3.6 mL/g) of R. chinensis anthocyanins on basis of MS into MS/glycerol blend matrix. Results of physicochemical property determination showed that incorporation of CG or R. chinensis anthocyanins (2.4 mL/g and 3.6 mL/g) could significantly improve the thickness, moisture content, opacity, thermodynamic stability, EAB, hydrophilicity and pH and ammonia sensitivities, reduce the light transmittance and TS of the MS film. The antioxidant assay result showed that the MS-CG-RFE films had significant scavenging activity on DPPH radical in dose-dependent manners. Structural characterization of films showed that there were some intermolecular interactions between RFE and MS/CG in MS-CG-RFE films. Because of good pH and ammonia sensitivities, the MS-CG-RFE films showed visible color variations in response to the change in pork freshness and effectively indicated the freshness of pork. Our findings implied that MS-CG-RFE films could be used as a smart packaging film to track the freshness of foods containing animal proteins.